gtablet clock time is wrong! - G Tablet General

Yes, it's true. The time reading on the gtablet is 4 minutes slower than the official U.S gov't time. Why? Check it yourself.

mine is showing the same exact time as my Fios STB and my Verizon cell phone, neither of which are user controlled. Anything with the words "government" and "official" are usually slow...

I'm in my 60's,
4min one way or another really doesn't register in my scheme of life
Sent from my VEGAn-TAB-v1.0.0b5.1.1 using XDA Premium App

andls said:
Yes, it's true. The time reading on the gtablet is 4 minutes slower than the official U.S gov't time. Why? Check it yourself.
Click to expand...
Click to collapse
You can force the correct time like this (type only the emboldened bits in):
Code:
$ [B]su[/B] [I]Become superuser[/I]
# [B]busybox mount -w -o remount /system[/B] [I]Mount /system read-write[/I]
# [B]cat > /etc/resolv.conf[/B] [I]Create a resolv.conf for ntpd[/I]
[B]nameserver 8.8.8.8[/B] [I]Use Google's public DNS servers[/I]
[B]nameserver 8.8.4.4[/B]
CTRL-D [I]Exit from cat[/I]
# [B]busybox mount -r -o remount /system[/B] [I]Mount /system read-only again[/I]
# [B]busybox ntpd -d -n -q -p 0.pool.ntp.org[/B] [I]Update date and time[/I]
# [B]busybox hwclock -w -u[/B] [I]Store in CMOS[/I]
The first few steps just have to be done once. To update the time in the future, just run only the busybox ntpd ... and the busybox hwclock ... commands.

Related

Setup Ubuntu Maveric with 3G Image It Works Running 2 Operating systems simultaneousl

UPDATE: 01/13/11 Scrap Most of this,
got a 3G working image works 10tmes better than anything i have seen.
UPDATE go here:http://forum.xda-developers.com/showthread.php?t=912544
have networking with hamachi, ssh works coolstuff:
trying to put it together (steps to create, and emulate on your computer, an image to get worken on your phone,) it works for the epic also which i have to say i prefer because of the slide-out, ya no wat. as soon as possible 2 DAYS TOPS
To Install Ubuntu Maveric on your Phone:
Of course you must have a rooted phone, since your rom must use a kernel with Loop support, I have only tested this on CyanogenMod Nightly build 199
make sure you have busybox installed
To create the image You have to start with a computer running Ubuntu or setup Virtual Box on a Windows computer,
or go here http://w3.impa.br/~gabrield/data/ubuntu-arm-development-rootfs.tar.bz2 to download the prebuilt one ( i havnt tested it)
1: Open Terminal in Ubuntu
2: Enter:
sudo apt-get install rootstock. After installing Rootstock, again in ubuntu terminal,
​Enter,
3: sudo rootstock --fqdn ubuntu --login ubuntu --password ubuntu --imagesize 2G --notarball .
​You can change login and password to your desire and ​also change imagesize 1G 2G and soforth
Your ubuntu-arm.img will be created in about 15 min or so. Take that arm.img and use Ark to crush it down to under 200meg if you would like or and or change name to ubuntu.img.
Using file manager, Create a folder (on your phone) /sdcard/ubuntu
and transfer ubuntu.img to your sdcard folder, ubuntu.
Copy the following text including the (#) and paste into notepad++
(get it http://notepad-plus-plus.org/download) or in linux gedit or Eqvlnt.
Save as sdcard/ubuntu/bootubuntu (no extension)nothing more.
#modprobe ext2
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
export kit=/sdcard/ubuntu
export bin=/system/bin
if [ ! -d /data/local/ubuntu ]
then
mkdir /data/local/ubuntu
fi
export mnt=/data/local/ubuntu
export PATH=$bin:/usr/bin:/usr/sbin:/bin:$PATH
export TERM=linux
export HOME=/root
mknod /dev/loop1 b 7 0
losetup /dev/block/loop1 /sdcard/ubuntu/ubuntu.img
mount -t ext2 /dev/block/loop1 /data/local/ubuntu
#mount -o loop,noatime -t ext2 $kit/ubuntu.img $mnt
mount -t devpts devpts $mnt/dev/pts
mount -t proc proc $mnt/proc
mount -t sysfs sysfs $mnt/sys
sysctl -w net.ipv4.ip_forward=1
echo "Setting /etc/resolv.conf to Google Open DNS 8.8.8.8 and 8.8.4.4"
echo "nameserver 8.8.8.8" > $mnt/etc/resolv.conf
echo "nameserver 8.8.4.4" >> $mnt/etc/resolv.conf
echo "Setting localhost on /etc/hosts "
echo "127.0.0.1 localhost" > $mnt/etc/hosts
echo "READY TO ROCK AND ROLL BABY! "
echo "Brought to you by NexusOneHacks.net and the open source community! "
echo " "
chroot $mnt /bin/bash
#After exit command is executed clear it all up
echo " "
echo "Shutting down Ubuntu"
umount $mnt/dev/pts
umount $mnt/proc
umount $mnt/sys
umount $mnt
losetup -d /dev/loop1
AND DO THE SAME FOR THE NEXT 4 FILES AND NAME THEM CORRECTLY AND USE THE RIGHT TEXT EDITOR
This next file is called sdcard/ubuntu/unionfs (remember no file ext.)
busybox insmod unionfs
mount -t unionfs -o dirs=$mnt/etc=rw:/etc=ro unionfs /etc
mount -o remount,rw /
ln -s $mnt/lib /
for x in \
bin boot home media mnt \
opt selinux srv usr var
do
ln -s $mnt/$x /
done
rmdir /root
ln -s $mnt/root /
mount -o remount,ro /
mount -t unionfs -o dirs=$mnt/sbin=rw:/sbin=ro unionfs /sbin
mount -t unionfs -o dirs=$mnt/dev=rw:/dev=rw unionfs /dev
mount -t devpts devpts /dev/pts
This next file is called sdcard/ubuntu/fsrw (remember no file ext.)
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
echo "Filesytem remounted as read/write"
This next file is called sdcard/ubuntu/mountonly (remember no file ext.)
# Based on Saurik's remount.sh - modified by Mark Walker of http://www.androidfanatic.com
# Email [email protected]
modprobe ext2
clear
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
export kit=/sdcard/debian
export bin=/data/local/bin
export mnt=/data/local/mnt
export PATH=$bin:/usr/bin:/usr/sbin:/bin:$PATH
export TERM=linux
export HOME=/root
busybox insmod ext2
clear
echo " "
mount -o loop,noatime $kit/debian.img $mnt
mount -t devpts devpts $mnt/dev/pts
mount -t proc proc $mnt/proc
mount -t sysfs sysfs $mnt/sys
echo "Custom Linux IMG Mounter V1.0 - by Mark Walker"
echo "WEB: http://www.androidfanatic.com"
echo "EML: [email protected]"
sleep 1
echo "AutoMounter started"
sleep 1
echo "REBOOT PHONE TO PROPERLY DISMOUNT"
echo " "
# chroot $mnt /bin/bash
This next file is called sdcard/ubuntu/ubuntu.sh (this one has .sh for file ext)
mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system
modprobe ext2
clear
rm -f /data/local/bin/fsrw
rm -f /data/local/bin/bootubuntu
rm -f /data/local/bin/unionfs
rm -f /data/local/bin/installer.sh
rm -f /data/local/bin/mountonly
mkdir /data/local/mnt
clear
rm /system/bin/fsrw
rm /system/bin/bootubuntu
rm /system/bin/unionfs
rm -/system/bin/mountonly
cp -f fsrw /system/bin
cp -f bootubuntu /system/bin
cp -f unionfs /system/bin
cp -f mountonly /system/bin
cd /sdcard/ubuntu
chmod 4777 *
cd /system/bin/
chmod 4777 *
cd /
clear
echo " "
echo "Ubuntu Chroot Bootloader v0.1"
echo "Ubuntu Bootloader is now installed!"
echo "This process does NOT damage Android OS!"
echo " "
echo "Original Installer by Charan Singh"
echo "Modified for Ubuntu Chroot by Max Lee at NexusOneHacks.net"
echo " "
echo "To enter the Debian Linux console just type 'bootubuntu'"
bootubuntu
After you have,
bootubuntu
fsrw
mountonly
unionfs
ubuntu.sh
ubuntu.img
in your /sdcard/ubuntu folder
Open adb shell
Enter:
su
cd /sdcard/ubuntu
sh ./ubuntu.sh
apt-get update
apt-get install tightvncserver
apt-get install lxde
export USER=root
vncserver :0 -geometry 1024x800
cat > front
export USER=root
cd /
rm -r -f /tmp
mkdir /tmp
cd /
vncserver :0 -geometry 1024x800
(cntrl D, cntrl D then Enter)
cat front /root/.bashrc > temp
cp temp /root/.bashrc
Get Android VNC for you phone (market)
open app
enter 5900 for port
enter password you setup for vncserver
set graphics for 24 bit
Connect
let the fun begin
Next update: How to network with Hamachi
It does work
ill give this a try tommorow..
Gonna, maybe, dive in.
Fire up an ubuntu image and then connect to it with vnc... I think I'll wait for the movie to come out and save the battery life. Hey wait, thats an idea. We could make a video of someone using ubuntu, and then play it on our phone so it feels like ubuntu. Might even do better on the battery life / "useful" factor.
(I've seen this method before, so keep in mind I am poking fun at the people who would want to do this and not you for sharing this with us.)
flexgrip said:
Fire up an ubuntu image and then connect to it with vnc... I think I'll wait for the movie to come out and save the battery life. Hey wait, thats an idea. We could make a video of someone using ubuntu, and then play it on our phone so it feels like ubuntu. Might even do better on the battery life / "useful" factor.
(I've seen this method before, so keep in mind I am poking fun at the people who would want to do this and not you for sharing this with us.)
Click to expand...
Click to collapse
What is your superior method?
I believe he's referring to the idea of running Ubuntu on a phone in general. I have trouble seeing the usefulness, but it's very interesting. Thanks for the post, OP.
Sent from my PC36100 using XDA App
TheMagicalSock said:
I believe he's referring to the idea of running Ubuntu on a phone in general. I have trouble seeing the usefulness, but it's very interesting. Thanks for the post, OP.
Sent from my PC36100 using XDA App
Click to expand...
Click to collapse
If that's the case, then I gave him too much credit. This is a fantastic How-To.
I put this to anyone:
UPDATE:
FIXED WILL POST FIX SOON (had to use MAKEDEV)
THIS IS GREAT YAHOOOO
Hi i was hoping you could help me with this problem:
I am using (on a dedicated ubuntu computer with Maverick edition)"https://wiki.ubuntu.com/ARM/RootfsFromScratch" example to create a qemu image using "sudo rootstock --fqdn ubuntu --login ubuntu --password ubuntu --seed nano --notarball --imagesize 3G".
I have also used the "sudo project-rootstock/rootstock --fqdn ubuntu --login ubuntu --password ubuntu --seed nano --notarball --imagesize 3G"
and: "sudo ./rootstock --fqdn ubuntu --login ubuntu --password ubuntu --seed nano --notarball --imagesize 3G" way.
They all work great. I am able to load the image with qemu, got ssh setup and working alls great in life.
The problem lies HERE.......
I am using these images (mostly for fun), to setup ubuntu onto my Evo and Epic smartphones using this method: "http://forum.xda-developers.com/showthread.php?t=881401" to chroot the image.
ITS AWSOME IT WORKS AND LOTS OF FUN!
well sorry for screaming but it really excites me this open source Ubuntu Stuff. (i am a win user, but I found a new toy)
Using the prebuilt image everything works excellent (except for the small image size 2G) that is why i need to use my 3G built image.
My problem: My built image works flawlessly as well, with one exception, (that i have noticed) is, inside ubuntu (on my phone chrooted with android) the terminals do not have a prompt# only black, square curser, and will not except input. I have to use the terminal program inside android to apt-get and such.
I have noticed with my build images, using apt-get during install, i see "Can not write log, openpty() failed (/dev/pts not mounted?)"
error. My reserch says terminals wont work if system cannot write to /dev/pts.
The prebuilt image does not have this issue.
What is the differance with the prebuilt that is offered here "wget -c http://w3.impa.br/~gabrield/data/ubuntu-arm-development-rootfs.tar.bz2", and the images I create using the steps outlined in the article.
Is there modifications prior to or after creation, or is this someting different altogether.
I really have been pulling the little bit of hair i have left out of my head for a week now
HELP.!!!
p.s. I have tried all builds etc; karmic,lucid same results
Try mounting dev/pts says it is mounted but busy
To Homefix :
Did you try "sudo apt-get install ..." ?
To change bash prompt did you try "export PS1=#" ?
What is an output of "id" command? If you get anything other than root, add that user to root group, or just "su" maybe?
Can someone please post some pics or a video of this working?
generalExpert said:
Can someone please post some pics or a video of this working?
Click to expand...
Click to collapse
Its the same as having Ubuntu on your desktop monitor only smaller
Wouldn't unity work better on a phone
Sent from my PC36100 using XDA App

[ACS][Kernel][How-To] Make your own Plus Kernel **Updated 9/18**

Even though I put this in the Epic forum, this will work on any zImage based android kernel as far as I am aware.. from Eclair to Gingerbread, maybe previous, maybe in the future..
I will post my tweaks here (please give credit), and even my ext4 modules (again please give credit, to both me and Rodderik, as he helped with one of them) for Gingerbread.
First off, you will need either a linux based computer, a remote linux box, or a virtual machine.. I don't think cygwin will be enough. I'm not going to go through the steps of setting that up because it's out of the scope of this How-to, maybe in another post.
Second, you need some scripts to decompile the initramfs from the kernel, or you can do it manually with grep or a hex editor ( I don't recommend ), I'll provide the scripts I use, which I procured from supercurio's project voodoo github then modified to work a little better with zImages that have 2 signatures (happens sometimes) like EH06...
http://chris41g.devphone.org/voodoo.tar.gz
in voodoo/config.sh you will need to set your compiler path.
also read the readme.txt it will pretty much describe how it all works, and remember all the gingebread leaks only work with gzip compression when repacking.
to unpack the initramfs
Code:
./extracter.sh -s "/path/to/original/zImage" -d "/path/where/you/want/initramfs/"
and after a few minutes your initramfs will be wherever you told it to go with -d.
now the initramfs is pretty much the meat and potatoes when repacking a kernel.
adding EXT4
this is a pretty popular request...
to do this you need just a few things, the correct modules, and the correct mount options. both of which i will provide.
the modules for Gingerbread are called ext4.ko and mbcache.ko and need to added to lib/modules in the initramfs - link http://chris41g.devphone.org/gbext4modules.tar.gz
then the following lines need to be added to init.rc lpm.rc and recovery.rc
Code:
insmod /lib/modules/mbcache.ko
insmod /lib/modules/ext4.ko
right around the lines that look like
Code:
insmod /lib/modules/fsr.ko
insmod /lib/modules/fsr_stl.ko
insmod /lib/modules/rfs_glue.ko
insmod /lib/modules/rfs_fat.ko
to the same files look for:
Code:
mount rfs /dev/block/stl9 /system check=no
and under it add
Code:
mount ext4 /dev/block/stl9 /system noatime nodiratime errors=continue
now in init.rc and recovery.rc look for
Code:
mount rfs /dev/block/stl10 /data nosuid nodev crypt check=no
and under it add
Code:
mount ext4 /dev/block/stl10 /data nosuid nodev crypt noatime nodiratime
and look for
Code:
mount rfs /dev/block/stl11 /cache nosuid nodev check=no
and under it add
Code:
mount ext4 /dev/block/stl11 /cache nosuid nodev noatime nodiratime errors=continue nobh data=writeback barrier=0 noauto_da_alloc
now usually there will be some stuff you need to comment out.. which means adding # to the beginning of the line..
i always comment this out because it can mess with my tweaks later on and its useless
Code:
mount rfs /dev/block/stl9 /system ro remount
i also comment out or delete left over stuff for other phones that samsung has a habit of leaving in our init.rc... lazy people..
How to Root a Kernel Re-Pack:
This may seem basic, and to some it is, but I'm going to cover it anyway. Also it has changed in gingerbread, as you can't suid anything in /sbin, and that is the beginning of your PATH.
First we need some files.
su binary Stable - http://forum.xda-developers.com/showthread.php?t=682828 Beta - http://chris41g.devphone.org/su3.tar.gz
Superuser.apk Beta - http://chris41g.devphone.org/Superuser.apk
busybox binary (this one is dependent on whether you have purple cwm built in or not, since we havent got that far ill assume you dont) busybox 1.20.0 compiled by me http://chris41g.devphone.org/busybox
copy those files into /sbin in the initramfs, also do a
Code:
ln -s busybox sh
from the sbin directory in your initramfs on your linux box to make a symlink from sh to busybox
then goto the initramfs root
and do
Code:
ln -s sbin bin
to make a symlink from sbin to bin, it's probably not necessary but i always do it for consistency.
now go into /sbin and make a new sh script called whatever you want.
Code:
#!/system/bin/sh
# Remount filesystems RW
busybox mount -o remount,rw /
busybox mount -o remount,rw /system
#install busybox links
busybox cp /sbin/busybox /system/bin/busybox
/system/bin/busybox rm /sbin/busybox
busybox --install -s /system/bin
busybox --install -s /system/xbin
#establish root
busybox cp -f /sbin/su /system/bin/su
chmod 6755 /system/bin/su
busybox rm /sbin/su
busybox ln -s /system/bin/su /system/xbin/su
#check if Superuser.apk exist if not install but also delete bloat to make room
if [ ! -f "/system/app/Superuser.apk" ] && [ ! -f "/data/app/Superuser.apk" ] && [[ ! -f "/data/app/com.noshufou.android.su"* ]]; then
if [ -f "/system/app/Asphalt5_DEMO_ANMP_Samsung_D700_Sprint_ML.apk" ]; then
busybox rm /system/app/Asphalt5_DEMO_ANMP_Samsung_D700_Sprint_ML.apk
fi
if [ -f "/system/app/Asphalt5_DEMO_SAMSUNG_D700_Sprint_ML_330.apk" ]; then
busybox rm /system/app/Asphalt5_DEMO_SAMSUNG_D700_Sprint_ML_330.apk
fi
if [ -f "/system/app/FreeHDGameDemos.apk" ]; then
busybox rm /system/app/FreeHDGameDemos.apk
fi
busybox cp /sbin/Superuser.apk /system/app/Superuser.apk
fi
sync
# Fix screwy ownerships
for blip in conf default.prop fota.rc init init.goldfish.rc init.rc init.smdkc110.rc lib lpm.rc modules recovery.rc res sbin bin
do
chown root.shell /$blip
chown root.shell /$blip/*
done
chown root.shell /lib/modules/*
chown root.shell /res/images/*
#setup proper passwd and group files for 3rd party root access
# Thanks DevinXtreme
if [ ! -f "/system/etc/passwd" ]; then
echo "root::0:0:root:/data/local:/system/bin/sh" > /system/etc/passwd
chmod 0666 /system/etc/passwd
fi
if [ ! -f "/system/etc/group" ]; then
echo "root::0:" > /system/etc/group
chmod 0666 /system/etc/group
fi
# fix busybox DNS while system is read-write
if [ ! -f "/system/etc/resolv.conf" ]; then
echo "nameserver 8.8.8.8" >> /system/etc/resolv.conf
echo "nameserver 8.8.4.4" >> /system/etc/resolv.conf
fi
sync
# patch to prevent certain malware apps
if [ -f "/system/bin/profile" ]; then
busybox rm /system/bin/profile
fi
touch /system/bin/profile
chmod 644 /system/bin/profile
# remount read only and continue
busybox mount -o remount,ro /
busybox mount -o remount,ro /system
Now you need to make a change in your init.rc file to call this new script..
add this to your init.rc in the services section, around where the factory bootanimation service is loaded.
Code:
# Custom Script Configuration
service userscript /system/bin/sh /sbin/[whateveryounamedyour].sh
user root
group system
critical
oneshot
now you have rooted your own repack...
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Adding init.d support...
this is pretty easy, didn't want to add another post..
Let's open up /sbin/[whateveryounamedyour].sh
right after installing Superuser.apk, lets add this section...
Code:
if [ -d /system/etc/init.d ]
then
logwrapper busybox run-parts /system/etc/init.d
fi
sync
There ya go, thats it, you're done..
-----------------------------------------------------------------------------------------------------------------------------------------------
Ok, since I'm on a roll haha lets go with bootanimations... they are different on Gingerbread..
this is all done in the init.rc so lets open that up in your text editor, I recommend Geany btw..
First off in GB I had to disable stock animations to make it not look like trash, because they won't always start at the same time.. but it's your option.. ymmv
Code:
service samsungani /system/bin/samsungani
user graphics
group graphics
disabled
oneshot
Comment that section if you want to disable the stock animations... you can leave it and custom animations will still work if you want, but fair warning, its weird...
Code:
service bootanim /system/bin/bootanimation
user graphics
group graphics
critical
oneshot
Add that section to enable custom animations..
I never have but just incase you want to, you can comment this section out to disable boot sounds..
Code:
service playsound /system/bin/playsound
user media
group system
disabled
oneshot
one more thing, the new binary works, but it doesn't know when to stop playing....
add this line to the very end of the init.rc
Code:
on property:sys.boot_completed=1
stop bootanim
Thanks to tanimn for help on that one...
Now remember, before gingerbread, custom animations were bootanimation.zip, but now they are sanim.zip you can leave it that way, or for the users sake you can crack open the [whateveryounamedyour].sh and make a workaround.
add this line to [whateveryounamedyour].sh before you remount the partitions at the end.
Code:
busybox ln -s /system/media/bootanimation.zip /system/media/sanim.zip
basically what that does is create a symlink from the users bootanimation.zip to sanim.zip, so when the bootanimation binary looks for sanim.zip its redirected to bootanimation.zip.. so the user can put bootanimation.zip in the directory transparently without having to rename...
More to come, and I'm still taking request for additions to this how to....
awesome! thanks for the post... maybe I can start putting that programming class I had last semester to good use...
Joey
holy crap...I needed this about a month ago. thanks for putting it all in one place!! and jw....why do we need the mbcache.ko? ext4 worked fine without it, in a kernel I did.
sent from my uncyanogen modded epic 4g. with the key skips.
You know I don't even know what a plus kernel does but I use it for the old school android boot animation
Sent from my SPH-D700 using xda premium
ahh nice! cant wait for the others!
I really wanted this thank for the info!
Sent from my SPH-D700 using xda premium
Anyone ... what does the plus kernel do ?
Sent from my SPH-D700 using xda premium
Digglez said:
Anyone ... what does the plus kernel do ?
Sent from my SPH-D700 using xda premium
Click to expand...
Click to collapse
Its basically a stock kernel with mods.
Sent from my SPH-D700 using xda premium
Any mods besides the boot animation
Sent from my SPH-D700 using xda premium
Digglez said:
Any mods besides the boot animation
Sent from my SPH-D700 using xda premium
Click to expand...
Click to collapse
So far, adding ext4 modules is the only mod he's shown how to do. He'll be updating his thread with more mods soon.
Sent from my SPH-D700 using xda premium
Digglez said:
Any mods besides the boot animation
Sent from my SPH-D700 using xda premium
Click to expand...
Click to collapse
You can include boot animation...he just hasn't shown how to do it yet like ceelos said
Like I said in the first post, I will take request, within reason...
chris41g said:
Like I said in the first post, I will take request, within reason...
Click to expand...
Click to collapse
Any way you can show us how to bake mods into the kernel? Like say, superuser, so we make pre-rooted kernels
Sent from my SPH-D700 using xda premium
Ceelos09 said:
Any way you can show us how to bake mods into the kernel? Like say, superuser, so we make pre-rooted kernels
Sent from my SPH-D700 using xda premium
Click to expand...
Click to collapse
Updated just now with rooting, init.d support, and bootanimations..
Could you add how to do a cwm redirector? I've searched everywhere and can't find how.
that will be one of the upcoming topics..
chris41g said:
Updated just now with rooting, init.d support, and bootanimations..
Click to expand...
Click to collapse
Thanks Chris!
Sent from my SPH-D700 using xda premium
Hope your not doing this because you plan on leaving ! D;
But once again thanks for the info ill read it daily to make sure I understand it all!
Sent from my SPH-D700
I don't plan on going anywhere... but I also don't plan on being the only one repacking kernels forever either =]
chris41g said:
that will be one of the upcoming topics..
Click to expand...
Click to collapse
Awesome
chris41g said:
I don't plan on going anywhere... but I also don't plan on being the only one repacking kernels forever either =]
Click to expand...
Click to collapse
Hopefully soon we won't have to repack them, just recompile

[Guide] [Tweaks] Android Security Hardening

Lately I had been researching on how to further secure Android against Exploits, Malware, and Privacy issues. Some, if not most, of this guide is for the more paranoid users but I believe it is usefull information for everyone. I will try to keep it as easy to follow as possible.
Part 1 - ADB & Root:
What is ADB:
ADB (A.K.A the Android Debug Bridge) is a tool used by developers to allow access to an android device via a computer. The program consists of a server (ADBD) which lives on the phone/tablet and the client (ADB) which lives on the computer. This allows dev's to quickly access logs and install applications over a command shell.
The Threat:
While ADB is usefull if it is left on an attacker can use it to gain access to the device and dump logs, bypass the lock screen, root the device, steal credentails and more. One such attack is Kos' P2P-ADB. This framework allows an attack to bypass most (if not all) security if ADB is enabled on the device.
The Solution:
The easiest solution is to simply disable Degbuging. The setting is disabled by default but most custom roms have it enabled. To disable (on ICS/JB) it go to:
Code:
Settings ---> Developer Options ---> Android Debugging
Ensure Android debugging is unchecked.
For the more paranoid:
Adb actually relies on the ADBD binary. On most AOSP roms the binary is stored in /sbin/adbd if you change the permissions to 000 it can no longer execute and can't be used at all. One way to achieve this is by using this init.d script:
Code:
# Disable the adbd daemon
mount -o rw,remount -t rootfs rootfs /
chmod 000 /sbin/adbd
mount -o ro,remount -t rootfs rootfs /
mount -o ro,remount /system
Save the code to a file called 99secure and place it in /etc/init.d/ If your rom supports init.d the script will execute on boot and remove the adbd permissions so it can't run.
What is root/superuser:
The superuser is a special user account used for system administration. Depending on the operating system, the actual name of this account might be: root, administrator, admin or supervisor. In some cases the actual name is not significant, rather an authorization flag in the user's profile determines if administrative functions can be performed.
Click to expand...
Click to collapse
The root user has full access to the system and can perform almost any task. Most custom ROMs ship with root enabled.
The problem:
Running with root enabled is inherently insecure. If a malicous app is allowed to run with root permisions it has full access to the system and can do what ever it wants (delete information, steal passwords, keylog, activate the camera, etc.)
The Solution:
If you are running a CyanogenMod Rom you can disable root by going to:
Code:
Settings ---> Developer Options ---> Root Access ---> Disabled
Alternatively you can change the permisions of the "su" binary to 000 with:
Code:
mount -o rw,remount /system
chmod 000 /system/xbin/su
mount -o ro,remount /system
Part 2 - Bluetooth:
Bluetooth is a great technology that allows close range (~30m) wireless comunication between devices such as headsets and speaker phones.
The Problem:
Bluetooth is a wide open whole for an attacker to gain access to your device. There are multiple exploits against bluetooth (such as bluejacking). While most aren't widely used bluetooth should be disabled when not in use.
The Solution:
Disable bluetooth via the settings app:
Code:
Settings ---> Bluetooth ---> Off
Alternatively you can disable the bluetooth service/daemon:
Code:
mount -o rw,remount /system
chmod 000 /system/bin/bluetoothd
mount -o ro,remount /system
and even the bluetooth device (this was done on a Galaxy Nexus running CM10 JB):
Code:
mount -o rw,remount /system
chmod 000 /dev/ttyO1
mount -o rw,remount /system
After that is done bluetooth can no longer be turned on by accident or a malicous attacker (provided they don't have root).
Part 3 - NFC:
What is NFC:
Near field communication (NFC) is a set of standards for smartphones and similar devices to establish radio communication with each other by touching them together or bringing them into close proximity, usually no more than a few centimetres. Present and anticipated applications include contactless transactions, data exchange, and simplified setup of more complex communications such as Wi-Fi.[1] Communication is also possible between an NFC device and an unpowered NFC chip, called a "tag".[2]
NFC standards cover communications protocols and data exchange formats, and are based on existing radio-frequency identification (RFID) standards including ISO/IEC 14443 and FeliCa.[3] The standards include ISO/IEC 18092[4] and those defined by the NFC Forum, which was founded in 2004 by Nokia, Philips and Sony, and now has more than 160 members. The Forum also promotes NFC and certifies device compliance.[5]
Click to expand...
Click to collapse
As per Wikipedia
The Problem:
This year at defcon NFC was shown to be vulnerable to attack (http://forum.xda-developers.com/showthread.php?t=1832186). Another example is the recent Samsung Exploit which can be executed by NFC tags as well.
The Solution:
NFC can be disabled by:
Code:
Settings --- > Wireless & Networks ---> NFC
Alternatively you can disable the NFC Device:
Code:
mount -o rw,remount /system
chmod 000 /dev/ttyO3
mount -o rw,remount /system
Part 4 - Network Attacks:
Just like a computer android is succeptable to attacks over the network. Bellow is a init.d script that will harden the TCP/IP stack:
Code:
# hardening TCP/IP stack for IPV4
sysctl -w net.ipv4.icmp_echo_ignore_broadcasts=1 #ICMP broadcast
sysctl -w net.ipv4.conf.all.accept_redirects=0 # ICMP redirects ipv4
sysctl -w net.ipv6.conf.all.accept_redirects=0 #ICMP redirects ipv6
sysctl -w net.ipv4.conf.all.send_redirects=0 # ICMP redirects
sysctl -w net.ipv4.conf.all.accept_source_route=0 #source routing disable
sysctl -w net.ipv4.conf.all.forwarding=0 #Forwarding traffic
sysctl -w net.ipv4.conf.all.rp_filter=1
sysctl -w net.ipv4.conf.all.log_martians=1 #filter martians
sysctl -w net.ipv4.tcp_max_syn_backlog=1280 # TCP syn half-opened
sysctl -w net.ipv4.ip_forward=0
sysctl -w net.ipv4.tcp_syncookies=1
Android also runs IPTables ( A firewall). You can change this by script or a nice GUI tool calledDroid Wall
Part 5 - Removing unneeded applications:
These commands will remove some applications that aren't needed and may have internet access. The bottom ones are kept for root only:
Code:
rm -f /system/xbin/irsii
rm -f /system/xbin/nano
rm -f /system/xbin/nc
rm -f /system/xbin/telnet
rm -f /system/xbin/telnetd
rm -f /system/xbin/opcontrol
chmod 740 /system/xbin/rsync
chmod 740 /system/xbin/strace
chmod 000 /system/bin/bluetoothd
chmod 750 /system/bin/iptables
chmod 750 /system/bin/ping]
There may be more you want to remove like ssh.
I personally removed "Packet Management" as well to prevent installing apps over USB:
Code:
# disable the Packet Management binary
chmod 000 /system/bin/pm
Part 6 - Removing APK's:
You can also remove unneeded APK's by:
Code:
mount -o rw,remount /system
rm -r /system/app/[apk name here]
mount -o ro,remount /system
I removed these apps:
Bluetooth.apk
NFC.apk
Development.apk
DrmProvider.apk (You may not want to do this if you use the playstore)
Email.apk ( I use K-9 instead)
Exchange.apk (I don't need it you may)
PackageInstaller.apk ( Used to install apps. Don't remove if you want to install apps).
Click to expand...
Click to collapse
What apps you can and can't remove
Part 7 - Misc:
Personally I don't use the playstore/Google Framework as it sends back WAY to much info for me to trust it. I also reccomend using Full Device Encryption and a secure Kernel such as FuguMod.
Alot of the information I got is from this Sans guide
I will be posting more as I look into other security options
Let me know if I missed anything and please hit thanks if I helped at all.
Bellow is the init.d script I am using (modified from the Sans guide) ** ONLY TESTED ON A GSM GALAXY NEXUS ***:
Code:
#!/system/bin/sh
# Customize some parameters and lockout the SO
# July 2011
mount -o rw,remount /system
# Disable Bluetooth
chmod 000 /dev/ttyO1
#Disable NFC
chmod 000 /dev/ttyO3
# hardening TCP/IP stack for IPV4/IPV6
sysctl -w net.ipv4.icmp_echo_ignore_broadcasts=1 #ICMP broadcast
sysctl -w net.ipv4.conf.all.accept_redirects=0 # ICMP redirects ipv4
sysctl -w net.ipv6.conf.all.accept_redirects=0 #ICMP redirects ipv6
sysctl -w net.ipv4.conf.all.send_redirects=0 # ICMP redirects
sysctl -w net.ipv4.conf.all.accept_source_route=0 #source routing disable
sysctl -w net.ipv4.conf.all.forwarding=0 #Forwarding traffic
sysctl -w net.ipv4.conf.all.rp_filter=1
sysctl -w net.ipv4.conf.all.log_martians=1 #filter martians
sysctl -w net.ipv4.tcp_max_syn_backlog=1280 # TCP syn half-opened
sysctl -w net.ipv4.ip_forward=0
sysctl -w net.ipv4.tcp_syncookies=1
# Removing/ disabling unnecessary binaries. Some of them have access to Internet
rm -f /system/xbin/irsii
rm -f /system/xbin/nano
rm -f /system/xbin/nc
rm -f /system/xbin/telnet
rm -f /system/xbin/telnetd
rm -f /system/xbin/opcontrol
chmod 740 /system/xbin/rsync
chmod 740 /system/xbin/strace
chmod 000 /system/bin/bluetoothd
chmod 750 /system/bin/iptables
chmod 750 /system/bin/ping
## This is the last step of the hardening
# do a backup before
# disable the Packet Management binary
chmod 000 /system/bin/pm
# Disable the adbd daemon
mount -o rw,remount -t rootfs rootfs /
chmod 000 /sbin/adbd
mount -o ro,remount -t rootfs rootfs /
mount -o ro,remount /system
Hardening android
How can I harden android to block certain web site or filtering the prono sites?
Have you made any further progress with locking down your phone. I switched from iPhone to android and I can't help but feel that the iPhone was more secure. Alot of my concern is that on Android I notice that even with a pin lock sometimes apps run on top of it and if you have a lock screen it sometimes seems to circumvent pin codes all together. Is the security of the phone now based on how secure the lock screen is?
As for your mods, It seems like most, if not all, of these mods require root access. Are you suggesting it is more secure to root your device and perform these mods than to leave it stock?
Also, how vulnerable is it to have a phone with an unlocked bootloader and a custom recovery? Doesn't that make it easier for someone with physical access to compromise your phone? I understand you can enable encryption which only encrypts the data partition but what about if the phone is already started up? Is there a way to harden it from physical attack other than disabling ADB?
Thank you
Josh
inaxsesable said:
Have you made any further progress with locking down your phone. I switched from iPhone to android and I can't help but feel that the iPhone was more secure. Alot of my concern is that on Android I notice that even with a pin lock sometimes apps run on top of it and if you have a lock screen it sometimes seems to circumvent pin codes all together. Is the security of the phone now based on how secure the lock screen is?
As for your mods, It seems like most, if not all, of these mods require root access. Are you suggesting it is more secure to root your device and perform these mods than to leave it stock?
Also, how vulnerable is it to have a phone with an unlocked bootloader and a custom recovery? Doesn't that make it easier for someone with physical access to compromise your phone? I understand you can enable encryption which only encrypts the data partition but what about if the phone is already started up? Is there a way to harden it from physical attack other than disabling ADB?
Thank you
Josh
Click to expand...
Click to collapse
Check out my other threads for more information and tweaks like secdroid. As far as iOS goes its pitiful for security I work in computer forensics and the iPhone is the easiest phone to pull data off of. If you want security and or encryption stick android. iOS encryption is defeated by simply turning the phone on ( it loads the keys automatically from hardware). If you need more help please pm as I can reply quicker there!
Sent from my Nexus 4 using xda premium
Check out Secdroid. The thread is still here somewhere or go straight to Google Play...
Sent from my Nexus 10 using xda app-developers app
Tor has a comprehensive how-to
Tor has a comprehensive how-to @ their blog called "mission-impossible-hardening-android-security-and-privacy"

[Guide] Installing Debian on Android 4.2

Requirements:
An ARMv7 chipset (with VPFv3 if using armhf arch)
Loopback kernel support (if using img file as per this guide, otherwise could use dedicated partition on sdcard).
Rooted device
Busybox
Preparing an image:
On a linux machine setup filesystem for mounting on the android device, below I create a 2GB loopback image.
Code:
# dd if=/dev/zero of=wheezy-armhf.img bs=1M count=0 seek=2048
# mkfs.ext4 -F wheezy-armhf.img
# mount -o loop wheezy-armhf.img /debian
Now we populate the filesystem with the files to complete the debian installation.
Code:
# debootstrap --arch=armhf --variant=minbase --foreign wheezy /debian $DEBIANURL
# umount /debian
Complete installation:
Now on the android device we complete the debian installation.
Code:
# mount -o rw,remount rootfs /
# export LINUXROOT=/linux
# mkdir $LINUXROOT
# busybox mknod /dev/block/loop100 b 7 100
# losetup /dev/block/loop100 /path/to/wheezy-armhf.img
# mount -t ext4 /dev/block/loop100 $LINUXROOT
# busybox chroot $LINUXROOT /debootstrap/debootstrap --second-stage
# mount -t proc none $LINUXROOT/proc
# mount -t sysfs none $LINUXROOT/sys
# mount -o bind /dev $LINUXROOT/dev
# mount -t devpts none $LINUXROOT/dev/pts
Now you can setup any other mounts you want, for example I bind mount my external USB storage etc. Now to login to the debian environment and install ssh server:
Code:
# export TMPDIR=/tmp
# export USER=root
# export HOME=/root
# export SHELL=/bin/bash
# export TERM=linux
# export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/sbin:/usr/local/bin
# export LC_ALL=C
# export LANGUAGE=C
# export LANG=C
# busybox chroot $LINUXROOT /bin/bash
We are now inside debian envrionment and perform some first time setup:
Code:
# passwd root
# groupadd -g 3001 aid_net_bt_admin
# groupadd -g 3002 aid_net_bt
# groupadd -g 3003 aid_inet
# groupadd -g 3004 aid_net_raw
# groupadd -g 3005 aid_net_admin
# groupadd -g 3006 aid_net_bw_stats
# groupadd -g 3007 aid_net_bw_acct
# groupadd -g 3008 aid_net_bt_stack
# echo "deb $DEBIANURL wheezy main" >/etc/apt/sources.list
# apt-get update
# apt-get install openssh-server
# exit
# sync
Now have a SSH service running that allows to login via ssh. Note that if you wish to use networking for other user accounts add them to the aid_inet and aid_net_raw groups. For example for transmission I did:
Code:
# apt-get install transmission-daemon
# usermod -a -G aid_inet,aid_net_raw debian-transmission
# invoke-rc.d transmission-daemon restart
chroot: can't change root directory to '/debootstrap/debootstrap': No such file or di
Hi!
First, thanks for your guide, the only one I've seen for Android 4.2
So I have a nexus 4 on Android 4.3 with Paranoid Android custom ROM and rooted with busybox 1.21 JB bionic (included with the ROM). I've done all the steps above until chroot, which gave me an error:
Code:
[email protected]:/ # busybox chroot $LINUXROOT /debootstrap/debootstrap --second-stage
[COLOR="red"]E: No pkgdetails available; either install perl, or build pkgdetails.c from source[/COLOR]
1|[email protected]:/ #
So what now? how do I install Perl for android? Do I have to install microperl from busybox's site?
Please help me, I'm trying to install Debian for 4 days.
Pickout said:
Hi!
First, thanks for your guide, the only one I've seen for Android 4.2
So I have a nexus 4 on Android 4.3 with Paranoid Android custom ROM and rooted with busybox 1.21 JB bionic (included with the ROM). I've done all the steps above until chroot, which gave me an error:
Code:
[email protected]:/ # busybox chroot $LINUXROOT /debootstrap/debootstrap --second-stage
[COLOR="red"]E: No pkgdetails available; either install perl, or build pkgdetails.c from source[/COLOR]
1|[email protected]:/ #
So what now? how do I install Perl for android? Do I have to install microperl from busybox's site?
Please help me, I'm trying to install Debian for 4 days.
Click to expand...
Click to collapse
I have that same problem. Any solution by now?
Thanks.
m
mickmattes said:
I have that same problem. Any solution by now?
Thanks.
m
Click to expand...
Click to collapse
I'll look into it, but it sounds like it has not bootstrapped the image correctly.
Pickout said:
Hi!
First, thanks for your guide, the only one I've seen for Android 4.2
So I have a nexus 4 on Android 4.3 with Paranoid Android custom ROM and rooted with busybox 1.21 JB bionic (included with the ROM). I've done all the steps above until chroot, which gave me an error:
Code:
[email protected]:/ # busybox chroot $LINUXROOT /debootstrap/debootstrap --second-stage
[COLOR="red"]E: No pkgdetails available; either install perl, or build pkgdetails.c from source[/COLOR]
1|[email protected]:/ #
So what now? how do I install Perl for android? Do I have to install microperl from busybox's site?
Please help me, I'm trying to install Debian for 4 days.
Click to expand...
Click to collapse
No you don't need to install Perl. Something as gone wrong with one of the steps. I'll see what I can figure out. Are you using the armhf arch? Cause I could send you a premade image to see if that has any success for you.
Thanks for your help, I've finally found what's the problem (two weeks ago, I've forgotten this thread), but thanks!
(The problem was that the environment variables were not set up properly)
Thanks to these links, I've managed to install Debian 7 on a rooted Android phone. All credit goes to them:
http://linux-expert.net/?Trucs_et_astuces___Android___Tutoriel_%3A_Chroot_Debian (in french)
http://forum.xda-developers.com/showthread.php?p=45457799
http://forum.xda-developers.com/showthread.php?t=2312013
http://forum.xda-developers.com/showthread.php?t=631389
http://forum.xda-developers.com/showthread.php?t=1418546
http://forum.xda-developers.com/showpost.php?p=5671794&postcount=124
VNC
________________
I. On the PC
So first, you have to create the .img file that will contain the OS.
In a GNU/Linux environment (PC) and with the root permissions, type these commands:
Code:
# mkdir debian
# dd if=/dev/zero of=wheezy-armhf.img bs=1M count=0 seek=2048
[COLOR="Red"](NOTE: "of=" will be the name of our .img file and "seek=" the size of the file (MB). Here, we create a file named "wheezy-armhf.img" of 2 GB)[/COLOR]
# mkfs.ext4 -F wheezy-armhf.img
# mount -o loop wheezy-armhf.img /debian
Then we have to fill up the filesystem.
Code:
# debootstrap --foreign --arch=armhf wheezy debian/
# umount debian
Finally, move it to your SD Card. In my case, I moved it on /data/local/
II. On the phone
On your phone, in a terminal emulator and with the root permissions, type the following commands:
Code:
# mount -o rw,remount rootfs /
# export LINUXROOT=/linux
(NOTE: here we'll install Debian on the root of the internal memory, in "/", but we can also install Debian on the SD Card or in /data/loca/linux by changing the path after "LINUXROOT=")
# mkdir $LINUXROOT
# busybox mknod /dev/block/loop100 b 7 100
# losetup /dev/block/loop100 /sdcard/wheezy-armhf.img
# mount -t ext4 /dev/block/loop100 $LINUXROOT
# chroot $LINUXROOT /bin/sh
# export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
# /debootstrap/debootstrap --second-stage
The debootstrap's second part should start. Grab a cup of coffee while it's working!
When it's finish, leave the chroot by typing
Code:
# exit
# su
Let's mount the filesystem. We're close!
Code:
# mount -t proc none /proc
# mount -t sysfs none /sys
# mount -o bind /dev /dev
# mount -t devpts none /dev/pts
Now, we have to set the environment variable. Ensure that you have set the correct path of LINUXROOT in case you've chosen another path than /linux.
Code:
# export LINUXROOT=/linux
# export TMPDIR=/tmp
# export USER=root
# export HOME=/root
# export SHELL=/bin/bash
# export TERM=linux
# export LC_ALL=C
# export LANGUAGE=C
# export LANG=C
And finally, chroot.
Code:
# chroot $LINUXROOT /bin/bash
su
Welcome on Debian!
III. DNS and Mirrors
Set a DNS. We'll set the free Google DNS but you can set yours if you want.
Code:
echo -e "domain local\nsearch local\n" >> /etc/resolv.conf
echo -e "# DNS Google\nnameserver 8.8.8.8\nnameserver 8.8.4.4\n" >> /etc/resolv.conf
You can add mirrors to your sources.list if you want. For my case, I'm french so I added french mirrors:
Code:
# echo -e "## Debian Wheezy sources.list\n\n" > /etc/apt/sources.list
# echo -e "## Debian.org FR mirror\ndeb http://ftp.fr.debian.org/debian/ wheezy main contrib non-free\ndeb-src http://ftp.fr.debian.org/debian/ wheezy main contrib non-free\n\n" >> /etc/apt/sources.list
# echo -e "## Debian security updates\ndeb http://security.debian.org/ wheezy/updates main contrib non-free\ndeb-src http://security.debian.org/ wheezy/updates main contrib non-free\n >> /etc/apt/sources.list
IV. VNC
To access your Debian in a graphical environment from your PC or your phone, you have to set up a VNC Server and install a Desktop Environment. Let's install VNC and LXDE.
We'll follow the steps described on the LXDE wiki:
Code:
su
# apt-get update
# apt-get install lxde
# apt-get install tightvncserver
Set up the VNC server by typing the following command, which will ask you to set two passwords (let the second password if you want):
Code:
# vncserver
Kill the session:
Code:
# vncserver -kill :1
Go to /root/.vnc/ and edit the xstartup file: comment out #/etc/X11/xsession and add these two lines:
icewm
lxsession
Click to expand...
Click to collapse
To start a VNC session, type "vncserver -geometry <HEIGHT>x<WIDTH>". For the Nexus 4, we would type "vncserver -geometry 1184x768"
To access your Desktop Environment from your phone, download android-vnc-viewer and launch it.
In the password field, type your password. In the address field, type "127.0.0.1", in port type "5901" and select 24-bit color (4bpp).
V. Script
I've made three scripts to mount, launch and unmount Debian. Whenever you reboot your phone, you'll have to mount Debian, set the environment variables and chroot.
VI. Credit
All credit goes to them:
http://linux-expert.net/?Trucs_et_astuces___Android___Tutoriel_%3A_Chroot_Debian (in french)
http://forum.xda-developers.com/showthread.php?t=2312013
http://forum.xda-developers.com/showthread.php?t=631389
http://forum.xda-developers.com/showthread.php?t=1418546
http://forum.xda-developers.com/showpost.php?p=5671794&postcount=124
VNC
Sorry for my bad english
Thanks for your work and solution. However I did not try it yet, because I'm trying to do it with the following solution. Perhaps I'll do this one next weekend
http://whiteboard.ping.se/Android/Debian
I really like the idea of it.
Just have a look.
P.S: By the way, I'm running Pacman-Rom (4.3) and it seems to work, if you flash googy-Kernel or some other Kernel. CM-Kernel has
some kind of SElinux restriction, which prevents you from changing the debian root password.
Wow, it sounds amazing! I will sure give it a try next week too.
Thanks for the link!
Pickout said:
Wow, it sounds amazing! I will sure give it a try next week too.
Thanks for the link!
Click to expand...
Click to collapse
I got stuck in a bootloop after flashing. I'm quite sure, that I did everything correctly...
I think my Pacman-Rom (JB 4.3) is to blame.
Thanks for the guide, was looking for something like this. I tried it first on an SD card formatted to ext4 (wanted a larger than 4GB .img file) but it failed to work. Went back to fat32 and for now kept a 4GB .img and after following you guide, it worked perfectly.
Where can I find the img ?
Hello,
Thanks for this how too!!
But where can I find the img ? wheezy-armhf.img ?
Thanks for your help,
Cheers,
Mat
matthieuDroid said:
Hello,
Thanks for this how too!!
But where can I find the img ? wheezy-armhf.img ?
Thanks for your help,
Cheers,
Mat
Click to expand...
Click to collapse
you make it yourself: the dd-command in the beginning creates a file called wheezy-armhf.img and fills it with zeros.
need enlightenment
hello,
i'm follow the instruction but get stuck with
# chroot $LINUXROOT /bin/sh
chroot: can't execute 'bin/sh': No such file or directory
Click to expand...
Click to collapse
pls help
i'm using galaxy note 3 n900 with armv7

[Q] tizen mod 3 time zone option

i'm not using an android device but im using gear 2 neo, so i skipped pair screen with tapping 20 times, but i had a problem with timezone, so i solved it via shell
Code:
-sh-4.1# vconftool -g 6514 set -t string db/setting/cityname_id "IDS_WCL_BODY_CITYNAME_ISTANBUL"
-sh-4.1# vconftool -g 6514 set -t string db/setting/timezone_id "Asia/Istanbul"
-sh-4.1# rm -f /opt/etc/localtime
-sh-4.1# ln -s /usr/share/zoneinfo/Asia/Istanbul /opt/etc/localtime
and reboot, with no problem i set my time zone manually
so what i wonder is would developers of this mod consider adding time zone option to settings in next update of tizen mod?
gomestai said:
i'm not using an android device but im using gear 2 neo, so i skipped pair screen with tapping 20 times, but i had a problem with timezone, so i solved it via shell
Code:
-sh-4.1# vconftool -g 6514 set -t string db/setting/cityname_id "IDS_WCL_BODY_CITYNAME_ISTANBUL"
-sh-4.1# vconftool -g 6514 set -t string db/setting/timezone_id "Asia/Istanbul"
-sh-4.1# rm -f /opt/etc/localtime
-sh-4.1# ln -s /usr/share/zoneinfo/Asia/Seoul /opt/etc/localtime
and reboot, with no problem i set my time zone manually
so what i wonder is would developers of this mod consider adding time zone option to settings in next update of tizen mod?
Click to expand...
Click to collapse
Do you have a chart of sorts that tells us what different city names and time zones we can use?
gomestai said:
i'm not using an android device but im using gear 2 neo, so i skipped pair screen with tapping 20 times, but i had a problem with timezone, so i solved it via shell
Code:
-sh-4.1# vconftool -g 6514 set -t string db/setting/cityname_id "IDS_WCL_BODY_CITYNAME_ISTANBUL"
-sh-4.1# vconftool -g 6514 set -t string db/setting/timezone_id "Asia/Istanbul"
-sh-4.1# rm -f /opt/etc/localtime
-sh-4.1# ln -s /usr/share/zoneinfo/Asia/Istanbul /opt/etc/localtime
and reboot, with no problem i set my time zone manually
so what i wonder is would developers of this mod consider adding time zone option to settings in next update of tizen mod?
Click to expand...
Click to collapse
I am sorry but what do you mean by "shell?"
Do you mean the command prompt in Windows? Would be great to set it up for the Eastern Time Zone ( Toronto, Ontario is the closest to me )
Digiguest said:
I am sorry but what do you mean by "shell?"
Do you mean the command prompt in Windows? Would be great to set it up for the Eastern Time Zone ( Toronto, Ontario is the closest to me )
Click to expand...
Click to collapse
Make sure your Gear 2 is plugged into your computer, open a command prompt, cd into the directory that your sdb.exe file is in, and type "sdb shell" without the quotes.
D0M1N!X said:
Make sure your Gear 2 is plugged into your computer, open a command prompt, cd into the directory that your sdb.exe file is in, and type "sdb shell" without the quotes.
Click to expand...
Click to collapse
Cannot find that file on my drive.....is it something I need to download from here?
Digiguest said:
Cannot find that file on my drive.....is it something I need to download from here?
Click to expand...
Click to collapse
You need to download Tizen Wearable SDK from Samsung's website.
D0M1N!X said:
Make sure your Gear 2 is plugged into your computer, open a command prompt, cd into the directory that your sdb.exe file is in, and type "sdb shell" without the quotes.
Click to expand...
Click to collapse
D0M1N!X said:
You need to download Tizen Wearable SDK from Samsung's website.
Click to expand...
Click to collapse
got it plugged in and everything....Tizenmod 3 installed...go to activate shell and it says target not found.
NVM. Forgot to turn debugging on.
Still a problem....
gomestai said:
i'm not using an android device but im using gear 2 neo, so i skipped pair screen with tapping 20 times, but i had a problem with timezone, so i solved it via shell
Code:
-sh-4.1# vconftool -g 6514 set -t string db/setting/cityname_id "IDS_WCL_BODY_CITYNAME_ISTANBUL"
-sh-4.1# vconftool -g 6514 set -t string db/setting/timezone_id "Asia/Istanbul"
-sh-4.1# rm -f /opt/etc/localtime
-sh-4.1# ln -s /usr/share/zoneinfo/Asia/Istanbul /opt/etc/localtime
and reboot, with no problem i set my time zone manually
so what i wonder is would developers of this mod consider adding time zone option to settings in next update of tizen mod?
Click to expand...
Click to collapse
I got it to work....sort of. Figured out the shell part ( I think ) but now my watch is FIVE hours ahead of me.....
Can you see where I went wrong please? See attached pic.
EDIT: GOT IT!!!!
You MUST use America names if you are in Canada or the USA. ( Figures...LOL!!! ) First go to your CMD Window and run as admin ( right click and select run as admin )
Then you must go to whereever you installed your SDB command ( mine was the default install folder of the Tizen Wearables SDK/Tools section)
" cd\
cd tizen-wearables-sdk
cd tools
now type sdb devices
If you have debugging on it will detect your Gear 2
now type sdb root on
Now type sdb shell and paste the commands below ( making changes to COUNTRY/CITY in that format ) ( All cities with split names MUST have a _ in the space between the names )
Code:
vconftool -g 6514 set -t string db/setting/cityname_id "IDS_WCL_BODY_CITYNAME_NEW_YORK"
vconftool -g 6514 set -t string db/setting/timezone_id "America/New_York"
rm -f /opt/etc/localtime
ln -s /usr/share/zoneinfo/America/New_York /opt/etc/localtime
now reboot your Gear 2.
This is the code you must use for anyone living in the Eastern Time Zone. ( Ontario for the most part )
All credit goes to the op for making this find.
Skin1980 please include the ability to select changes to time zones in next rom please....would save on a LOT of trouble.
hi again, sorry for late reply but you know it was newyear
D0M1N!X said:
Do you have a chart of sorts that tells us what different city names and time zones we can use?
Click to expand...
Click to collapse
yes there is a list on wikipedia:
h t t p : / / en.wikipedia. o r g /wiki/List_of_tz_database_time_zones"
Click to expand...
Click to collapse
You can try. But also there is a file list on your tizen devices target folder. I add it below.
Türkiyede Yaşıyor isen su kodu girmelisin
vconftool -g 6514 set -t string db/setting/cityname_id "IDS_WCL_BODY_CITYNAME_ISTANBUL"
vconftool -g 6514 set -t string db/setting/timezone_id "Asia/Istanbul"
rm -f /opt/etc/localtime
ln -s /usr/share/zoneinfo/Asia/Istanbul /opt/etc/localtime
Click to expand...
Click to collapse
Most easy way to change date and time
Easiest way to change date and time Samsung Gear 2 Tizen
open cmd
Locate the folder with sdb and write following commands
1. sdb root on
2. sdb shell
3. date -s 20151204 //todays date in YYYY:MMD format
3. date +%T -s "19:56:00" // time in hh:mm:ss format
4. date //yahoo!! you are done
More Easy way
open cmd
1.sdb root on
2.sdb shell
rm -f /opt/etc/localtime //Remove Localtime file
ln -s /usr/share/zoneinfo/GMT+X /opt/etc/localtime //Your County GMT+X (Turkey GMT+3 , )
I was able to get the time zone changed thanks to this thread, but when I adjust the date and time as described in shuaib007's post, it works until the watch is restarted/booted, after which they've both reverted back to what they were. Is there a command or something else I'm missing? Thanks in advance.

Categories

Resources