Wednesday, December 28, 2011

Unix Tools - Commands Basic and Advance

( recommend : ctrl+f to search keyword or command you want )
Unix Command :


  1. ls -> show contents of current directory
  2. ls -l -> show as list with some detail
  3. ls -la -> show as list with more detail, size(byte)
  4. ls -i * -> to show all file's inode number
  5. dir -> show contents of current directory(cmd)
  6. cd direcotry -> go to directory
  7. cd .. -> go to back tree parent of current directory
  8. cd / -> go to root directory
  9. cd ~ -> go to home directory
  10. cd ${HOME} -> go to home directory
  11. vi file -> make new file or edit file with vi editor
  12. pico file -> make new file or edit file with pico editor
  13. mkdir directory .. -> make new directorys
  14. mkdir [my\ name] -> make new directory with name space
  15. rm files .. -> remove or delete files
  16. rm directory .. -> remove directory (directory must be empty)
  17. rm -r directory.. -> force remove directory even is not empty
  18. mv file1 file2 -> rename file1 to file2 in the same directory
  19. mv file1 dir/file1 -> move file1 to dir/ in current directory as file1
  20. cp file1 file2 -> copy file1 past file2 in the same directory
  21. cp file1 dir/file1 -> copy file1 to past in dir/ in current directory as file1
  22. cat file -> view file content without editing
  23. cat -n file -> view file with line number
  24. last -> show time of login on current server
  25. last -20 -> show time of login on current server by 20 last users
  26. w -> show who is currently logged in/out server (what user doing)
  27. who -> show who ..... (show ip)
  28. man xxx -> help for xxx command
  29. logout -> logout of server
  30. ssh user@hostname -> ssh to a host
  31. date -> show date time
  32. command1 ; command2 -> using multiple command by ";"
  33. chmod +xwr files ... -> change permission of files x:execute w:write r:read for all
  34. chmod u+??? files ... -> change permission for user ( +:add , -:remove , o:other , g:group)
  35. pwd -> show where you are now ($PWD)
  36. echo -> display a line of text
  37. echo [option] [string]
    -> echo -n Hello World (-n : no newline after string)
    Hello World
  38. passwd -> change password of user
  39. zip archivefile.zip file1 file2 ... -> compression file as zip
  40. unzip archivefile.zip -> extract file zip
  41. sftp [username]@[host]-> upload file from remote to host
    1. Ex. I using my macbook to connect with http://bangpra.informatics.buu.ac.th with my username
    2. Open terminal
      1. $> sftp username@bangpra.informatics.buu.ac.th
      2. password: ____
      3. sftp> ? // to get help
        1. using l__ for remote
        2. using __ for host
        3. using get to download file from host to remote
        4. using put to upload file from remote to host
  42. curl -o [URL] -> download file to into current directory from URL
  43. wget [URL] -> download file or directory into current directory
  44. wget -r [URL] -> download directory from URL to current directory
  45. export PS1="change hosting name $" >> change user display
  46. du -sh ${HOME} >> show disk usage from tree HOME
  47. find ${HOME} -type f -size +1M -print | xargs ls -lh >> find file bigger >= 1MB from tree HOME
  48. find ${HOME} -type f ! -name '*.mp3' -exec grep -l -- "findstring" {} \; >> to find findstring is contents in files which is not *.mp3 from tree HOME
  49. tar -cvjf archive.tar.bz2 files...Compression file *.tar.bz2
  50. tar -xvjf archive.tar.bz2 files...Extract file *.tar.bz2
  51. tar -tvjf archive.tar.bz2 files...List archive file *.tar.bz2
  52. tar -cvzf archive.tar.gz files...Compression file *.tar.gz
  53. tar -xvzf archive.tar.gz files...Extract file *.tar.gz
  54. tar -tvzf archive.tar.gz files...List archive file *.tar.gz
  55. tar -cvJf archive.tar.xz files...Compression file *.tar.xz
  56. tar -xvJf archive.tar.xz files...Extract file *.tar.xz
  57. tar -tvJf archive.tar.xz files...List archive file *.tar.xz
  58. ln source_file hlink_file...Make a hard link to source file
  59. ln -s source_file slink_file...Make a soft link / symbolic link to source file
  60. stat [option] <filename>... show file information
  61. od [option] <base> <binaryfile>...show content binary file Ex1. od -t x1 file.pdf ... show to show file.pdf as one byt

iOS 5.0 , 5.0.1 Untethered Jailbreaken for iPhone4,iPod touch,iPad1 Fully work

Since today 28th December 2011 as the present for Christmas Day, we got a news of every using iOS 5 Semi-jailbreaken and wait the Untethered Jailbreaken.

The instructions :
## If you device is Jailbreaken with tethered or semit-tethered just go to Cydia and wait Cydia updating finish then go to search "corona 5.0.1"and install that ok !!!!

Step 1. Download firmware update iOS 5.0.1 and update to you device by iTune 10.5 or later. ( You won't need to download it if you are in current iOS 5.0 or 5.0.1 )

Step 2. Download RedSn0w 0.9.10b2 for Mac OS or for Windows

Step 3. Extract each of them and Make new directory "Pwnage" in Desktop and Copy all file in it .
 
Step 4. Open redsn0w and follow it instruction.
* For windows
**Windows 7 users may want to try running the redsn0w executable mode as an administrator in Windows Vista compatibility. You can do this by right clicking the executable and selecting Properties from the contextual menu.

Once RedSn0w opens click the Jailbreak button
Step Five
Plug your iPhone into the computer and make sure its OFF then click the Next button
Step Six
RedSn0w will now guide you through the steps to get into DFU mode. You can find more help with DFU mode here
Hold down both the Home button and the Power button for 10 seconds.
Release the Power button and continue holding the Home button until RedSn0w detects the device.
Step Seven
Your iPhone will now reboot
Step Eight
RedSn0w will now prepare the jailbreak data.
Step Nine
Select Cydia from the list of options and click Next.
Step Ten
Your iPhone will now be rebooted again and RedSn0w will begin uploading the new RAM Disk and Kernel.
Step Eleven
Once this is complete you will be notified that RedSn0w is done. When your iPhone finishes rebooting (5 minutes or so) it will be jailbroken with Cydia on the SpringBoard.
* For Mac OS
Step One
Create a folder on your desktop called Pwnage
Download the latest RedSn0w from here and place it in the Pwnage folder. Likewise, download the 5.0.1 firmware from here and place it in the Pwnage folder. (Note: you do not need to download the 5.0.1 firmware if you are already on iOS 5.0.1)
Extract the RedSn0w zip file by double clicking it.
Step Two: (You can skip this step if iOS 5.0.1 is already installed on your device)
Connect your iPhone to the computer and launch iTunes.
Select your iPhone from the list of devices on the left. Now hold down Option and click the Restore button. Restore is preferred as it won't create any wasted space on your iPhone.
Navigate to the Pwnage folder on your desktop and select the 5.0.1 firmware ipsw. Click the Choose button to continue.
iTunes will now update your iPhone to the new firmware.
Step Three
Launch the redsn0w application from the redsn0w folder we extracted earlier.
Step Four
Once RedSn0w opens click the Jailbreak button
Step Five
Plug your iPhone into the computer and make sure its OFF then click the Next button
Step Six
RedSn0w will now guide you through the steps to get into DFU mode. You can find more help with DFU mode here
Hold down both the Home button and the Power button for 10 seconds.
Release the Power button and continue holding the Home button until RedSn0w detects the device.
Step Seven
Your iPhone will now reboot
Step Eight
RedSn0w will now prepare the jailbreak data.
Step Nine
Select Cydia from the list of options and click Next.
Step Ten
Your iPhone will now be rebooted again and RedSn0w will begin uploading the new RAM Disk and Kernel.
Step Eleven
Once this is complete you will be notified that RedSn0w is done. When your iPhone finishes rebooting (5 minutes or so) it will be jailbroken with Cydia on the SpringBoard.