1. When in doubt ..
man commands
Samples:
2. What's my Unix system name,
OS,CPU?
SunOS hostname
5.8 Generic_108528-06 sun4u sparc SUNW, Ultra-5_10 3. Where am I (current working
directory)?
4. Who am I?
6. What is my account info?
7. What is my default printer?
8. When pressing BackSpace
it shows ^H, how do I set it to work correctly?
9. Change directory
10. List contents of the directory
11. File permissions
13. Copy file(s)
14. Move files to another directory
15. Delete file(s)
16. Make a directory
18. Delete a directory that
contains files and subdirectories
19. Symbolic link (can span/accross
file systems)
20. Hard link (files contain
the same inode, can not span file systems)
Related:
Unix Books :-
Return to : - Unix System Administration
Hints and Tips
(c) www.sap-basis-abap.com All material on this site is
Copyright.
$ man talk
$ man grep
$
$
/export/home/user
$
$ who
am i ;
returns only your log in name and time.
5. What is my hostname?
$ hostname
$
$
$
$
$ cd
~+
; ~+
= cwd or "." wherein
~- previous working directory
$ cd
$HOME
; changes directory to
your home folder = cd
~
$ cd
../../hw1
$ cd
..
; moves one level up from
your current working directory
$
$ ls
-R
; lists recursively that
includes subdirectories
$ ls
-li
; displays long listing
with inode number, or -a
to list hidden files
$
$ chmod
u=rx, g=r, o=file
; allows user to read and execute,
group to read, no
read, write and execute for others
$ chmod
a=rxfile
; allows user, group and
others to read and execute
$ chmod
754 myfile7->
111 in binary represents rwx for user
5-> 101 in binary represents r-x for group
4-> 100 in binary represents r-- for others
12.
Read text file(s)
$ catmyfile
; alternately, you can
use more myfile
$ catmyfile
news mail
; read multiple files
$ cat
*ing
$
$ cp
* ../hw
$ cp
-r /home/mydir
/home/newdir
; copies everything in mydir
to newdir
$ cp
-p source destination
; retains existing permissions
(copy ACL along)
$ cp
-i source destination
; does not overwrite an
existing file
$
$ mvmyfile $HOME
$
$ rmmyfile?
; removes myfile1, myfile2, myfile3
and so on.
$
17. Delete an empty directory
$ rmdirmydir
$
$
symbolic link always has a=rwx permissions
$
Unix Forum
- Do you have a UNIX Question?
UNIX Programming, Certification,
System Administration, Performance Tuning Reference Books
Every effort is made to ensure the content integrity.
Information used on this site is at your own risk.
All product names are trademarks of their respective
companies.
The site www.sap-basis-abap.com is in no way affiliated
with or endorsed by any company listed at this site.
Any unauthorised copying or mirroring is prohibited.