please help..!!!
hi all,
i need help on certain questions. Can anybody help.
1) What is hard link and soft link ? what is the difference between them?
2) What is the difference between mkfs and newfs?
3) Given a Hard disk describe all the steps you will take to mount it to a directory named Ravi, starting from attaching it till mounting?
4) Describe all run levels?
5) How many Raid Levels are there and decribe them?
6) Give the command, which will tell me in which slot my hard disk is attached and like wise for all other devices?
7) What is the difference between /sbin and /bin directories?
8) What is boot block?
9) What is super block and how would you recover it if it gets corrupted?
10) Can boot block be recovered if corrupted?
11) How can you make an ipaddress permanent?
12) How will you set gateway while the system is running?
13) what is swap space and if my physical memory is of 1GB then what should be that for the swap space?
14) How do you do a Jumpstart?
15) I have a system with a n/w card and wish to attach second n/w card, how can you do so remotely?
16) Descriibe the steps to do a file restore of say /usr?
17) How many types of backup are there and descibe incremental backup, all levels?
18) What is the default File System?
19) What is /proc filesystem?
20) What is the difference between NIS and NIS+?
21) How would you configure NIS client?
22) The hard disk, which has already been backed up completely, has crashed, how would you restore the filesystems and data that were previously there?
23) A user complains that the system is slow, as a System Administrator what will you do?
24) What is the difference between Raid Level 0 and 1?
25) What does netstat command do?
26) How would you configure a secondary NIC card?
[1940 byte] By [
dushy] at [2007-11-25 23:40:50]

# 1
Do your own homework. :)
# 2
Sorry, I tried to stop myself but simply couldn't!
alan
> hi all,
>
> i need help on certain questions. Can anybody help.
>
> 1) What is hard link and soft link ? what is the
> difference between them?
Hard links are hard, soft links aren't
> 2) What is the difference between mkfs and newfs?
One is spelled M-K-F-S, the other is spelled N-E-W-F-S
> 3) Given a Hard disk describe all the steps you will
> take to mount it to a directory named Ravi, starting
> from attaching it till mounting?
Given a hard disk, I'm taking it home and you can't have it back.
> 4) Describe all run levels?
Solaris is an operating system, it doesn't "run." It's installed onto a stationary object.
> 5) How many Raid Levels are there and decribe them?
Raid is something pirates do.
> 6) Give the command, which will tell me in which slot
> my hard disk is attached and like wise for all other
> devices?
cat
> 7) What is the difference between /sbin and /bin
> directories?
sbin is the plural of bin
> 8) What is boot block?
A boot block is something that you use to remove your boots at the end of the day.
> 9) What is super block and how would you recover it
> if it gets corrupted?
A super block is a regular block with an ego problem. Send it to a psychiatrist for treatment.
> 10) Can boot block be recovered if corrupted?
If it's corrupted, report it to the police.
> 11) How can you make an ipaddress permanent?
IP Addresses aren't known to be in a family way.
Their transient at best.
> 12) How will you set gateway while the system is
> running?
Systems don't run. See Above.
> 13) what is swap space and if my physical memory is
> of 1GB then what should be that for the swap space?
If your box costs more than my box, then we should swap.
> 14) How do you do a Jumpstart?
Over a lake with a tire attached to a rope swing would be preferable.
> 15) I have a system with a n/w card and wish to
> attach second n/w card, how can you do so remotely?
I would have someone box up the machine and mail it to me, install a third n/w card, and then ship it back to them.
> 16) Descriibe the steps to do a file restore of say
> /usr?
/usr
> 17) How many types of backup are there and descibe
> incremental backup, all levels?
Backup is something that you do in an automobile.
> 18) What is the default File System?
The defualt filesystem can be found under /default.
> 19) What is /proc filesystem?
Not the default file system.
> 20) What is the difference between NIS and NIS+?
+
> 21) How would you configure NIS client?
By following the instructions on http://docs.sun.com
> 22) The hard disk, which has already been backed up
> completely, has crashed, how would you restore the
> filesystems and data that were previously there?
If it's crashed, leave it alone and let it sleep it off.
> 23) A user complains that the system is slow, as a
> System Administrator what will you do?
Agree
> 24) What is the difference between Raid Level 0 and
> 1?
1
> 25) What does netstat command do?
Checks your ability to spell netstat
> 26) How would you configure a secondary NIC card?
What is wrong with the unsecondary NIC card?
# 3
Thanks for the good belly laugh in the morning. Needed it.
# 4
/me agrees on both accounts.
1. Do your own fscking homework.
2. Thanks for the awesome answers :3 Loved them!
Speaking of...
========
>> 5) How many Raid Levels are there and decribe them?
> Raid is something pirates do.
>> 6) Give the command, which will tell me in which slot
>> my hard disk is attached and like wise for all other
>> devices?
> cat
========
Between these two answers I started dreaming how wonderful it would be to be a pirate cat! Roaming the seven back yards and raiding mouse villages! Meeo-argh!
# 5
Please point your browser to your favorite online bookstore and search for "Unix System Admnistration Handbook" by Evi Nemeth, et.al. When you find it, buy it. You will find all your questions answered there.
# 6
or get "Essential System Administration" by Eileen Frisch. I have the 2nd edition -- albeit over a decade old, but I heard the 3rd edition was released last year.
This one and the previous one will be more than sufficient to get you started.
Also, if you want to learn Solaris (and not just any *nix), try getting your hands on a book on Solaris Certification by Bill Calkins -- he had an excellent Solaris 7 book -- makes me certain the latest one will be awesome too...
# 7
If you go to my website at http://alanpae.tripod.comto "New to unix"there is a link for beginners that Sun updates. It's a starting point.alan
# 8
> 1) What is hard link and soft link ? what is the
> difference between them?
Hardlink:
different names pointing to same inode no. are called hard links.
command to make hardlink: $ln orig_filehardlink_file.
Hardlink doesn't contain "l" in permission bit ( -rwxrwxrwx ).
Cannot cross filesystems.
Direcoties cannot be hardlinked.
Softlink:
-
different names pointing to different inode no. are called soft links.
command to make softlink: $ln -s orig_filesoftlink_file.
softlink does contain "l" in permission bit ( lrwxrwxrwx ).
Can cross filesystems.
Directories can be softlinked.
> 2) What is the difference between mkfs and newfs?
mkfs is used to make filesystem with options for filesystem type as well as block size, generally used for partitions used by database where needs to vary block size.
newfs can make filesystem with default filesystem type and default block size.
> 3) Given a Hard disk describe all the steps you will
> take to mount it to a directory named Ravi, starting
> from attaching it till mounting?
step1: physically add a hard disk and reboot the system
step2: use #format ( this will scan all hard disk and show you the path of new hard disk) format this harddisk and label it., if want to partition it use fdisk also.
step3:make a file system on that disk using newfs or mkfs e.g.
# newfs /dev/rdsk/c0t2d0s7
step4: make a directory name Ravi
step5: use mount command
#mount/dev/dsk/c0t2d0s7 /Ravi
> 4) Describe all run levels?
Runlevel 0 Shuts down all running processes and halts the system.
Runlevel 1 Places the system in single-user mode. Single-user mode is used by the system administrator to perform maintenance that cannot be done when users are logged in. This runlevel may also be indicated by the letter S instead of the number 1. Solaris uses S for single-user mode.
Runlevel 2 Special multiuser mode that does not support file sharing.
Runlevel 3 Provides full multiuser support with the full range of services, including NFS file sharing. It is the default mode used on Solaris systems.
Runlevel 4 Unused. You can design your own system state and implement it through runlevel 4.
Runlevel 5 Solaris does not use this runlevel. Entering runlevel 5 on a Solaris system causes a system shutdown.
Runlevel 6 Shuts down all running processes and reboots the system.
> 5) How many Raid Levels are there and decribe them?
Raid 0: stripping
Raid 1: mirroring
Raid 10: stipping and mirroring
Raid 3: stripping with dedicated parity.
Raid 5: stipping with distributed parity.
> 6) Give the command, which will tell me in which slot
> my hard disk is attached and like wise for all other
> devices?
the nomenclature of harddisk will help u detecting that.
e.g.
c0t2d0
this means channel 0, target 2, device 0
> 7) What is the difference between /sbin and /bin
> directories?
/sbin contains executables/binaries used by superuser(root), while /bin contains general executable/binaries used by all.
> 8) What is boot block?
An area of a disk having information for loading the operating system that is needed to start a computer.
> 9) What is super block and how would you recover it
> if it gets corrupted?
Section of computer hard disk drive that contains information about the file system is called super block.
If it get corrupted, you have to search out alternate super block in same filesystem and restore it from there.
> 10) Can boot block be recovered if corrupted?
it can be recovered, but practically difficult.
> 11) How can you make an ipaddress permanent?
configure /etc/hostname.interface containg only host name
and /etc/hosts containg IPaddress and host name.
12) How will you set gateway while the system is
> running?
Configure /etc/defaultrouter
> 13) what is swap space and if my physical memory is
> of 1GB then what should be that for the swap space?
swap space is the space where memory dumps sleeping processes.
swap space should be a little more than twice of physical memory. If physical memory =1GB, swap space should be a little more than 2GB(~2.10GB)
> 14) How do you do a Jumpstart?
you will find steps at http://www.cs.duke.edu/~braun/jumpstart/jumpstart-server.html
> 15) I have a system with a n/w card and wish to
> attach second n/w card, how can you do so remotely?
Obviously remotely u cann't attach second network card physically, but as a solution of it, u can use virtual IP address by configuring it as:
#ifconfig er0:1 172.40.30.4 netmask 255.255.0.0 up
where er0 is interface name er0:1 is a virtual interface, 172.40.30.4 is IP u wish to assign to virtual interface.
> 16) Descriibe the steps to do a file restore of say
> /usr?
u can simply use #cp -r
or if the backup is in tar format , u can use #tar -xvf
> 17) How many types of backup are there and descibe
> incremental backup, all levels?
Backups can be incremental, differential, full.
incremental backup means the backup of files created/modified after last backup taken.
> 18) What is the default File System?
In solaris default file system is ufs.
> 19) What is /proc filesystem?
/proc is known as window to system because it shows all runtime parameters of system.
> 20) What is the difference between NIS and NIS+?
NIS
--
Machine name and user's name can be the same.
Names and commands are case sensitive.
Data is stored in two-column maps.
Uses no authentication.
An NIS record has a maximum size of 1024 bytes.
NIS+
Machine name and user names must be unique.
Names and commands are not case sensitive.
Data is stored in multicolumn tables.
Uses DES authentication.
An NIS record has no limit.
> 21) How would you configure NIS client?
1. Run domainname to see if an NIS domainname is returned. If a value is not returned, run domainname NIS_domainname and create /etc/defaultdomain containing the name of the NIS domainname.
2. Create a directory named /var/yp/binding/`domainname` if one does not already exist.
3. If you want the NIS client to broadcast for a NIS server (note: there must be a NIS server on your subnet), start NIS with /usr/lib/netsvc/yp/ypstart. If you want to manually specify one or more NIS server(s) to use, run ypinit -c and then /usr/lib/netsvc/yp/ypstart. Note that each manually specified NIS server must have an entry in /etc/hosts.
4. Modify the name service switch file (/etc/nsswitch.conf) to use the NIS databases. You may want to copy /etc/nsswitch.nis over /etc/nsswitch.conf. Make sure to modify the "hosts:" line in /etc/nsswitch.conf if you want to use DNS for hostname resolution:
hosts:dns nis files
> 22) The hard disk, which has already been backed up
> completely, has crashed, how would you restore the
> filesystems and data that were previously there?
it depends u have taken backup in which format, if used tar to backup,
then use #tar -xvf to restore it.
> 23) A user complains that the system is slow, as a
> System Administrator what will you do?
Check the for dead queues , if any clear them....for checking use "ipcs" for removing use "ipcrm"
check for the processes consuming max memory using "top", if possible kill those.
use "sar -a" to see status of CPU/disk input-output parameters, if needed increase swap space/memory etc.
> 24) What is the difference between Raid Level 0 and
> 1?
Raid 0: stripping
Raid 1: mirroring
> 25) What does netstat command do?
netstat show u network status.
> 26) How would you configure a secondary NIC card?
in same way as we configure primary NIC card, using "ifconfig" command.
# 9
[[[12) How will you set gateway while the system is
> running?
Configure /etc/defaultrouter]]]
Er...you probably meant:
route add -net default <ip of router>
netstat -rn will show you what the default route is set to (network id 0.0.0.0) is for default route...
# 10
[[[swap space should be a little more than twice of physical memory. If physical memory =1GB, swap space should be a little more than 2GB(~2.10GB)]]]
That is not entirely accurate. How much swap is needed by the system is decided by the amount of RAM you have physically on the server. There isn't really a steadfast rule of thumb to calculate how much swap (really slow memory) you need. If you have 8GB of RAM on your server, how much swap do you really need if all the applications put together never really use more than the 8gigs present?
On the other hand, if you want your system to dump the contents of it's memory to swap (usually does when system panicks), your swap will act as the dedicated dump device. In such a case, you'd need to have swap == RAM (usually a good idea).
# 11
> On the other hand, if you want your system to dump
> the contents of it's memory to swap (usually does
> when system panicks), your swap will act as the
> dedicated dump device. In such a case, you'd need to
> have swap == RAM (usually a good idea).
That's not necessary. By default, the dump contains only kernel pages, not user program pages (you can see and change the setting with 'dumpadm'). So that's normally only a fraction of the memory. Further, the dump is compressed, so even then it doesn't have to be too large.
--
Darren
# 12
> Runlevel 5 Solaris does not use this runlevel.
> Entering runlevel 5 on a Solaris system causes a
> system shutdown.
Poweroff state
> this means channel 0, target 2, device 0
controller 0 , target 2, device 0
> > 11) How can you make an ipaddress permanent?
> configure /etc/hostname.interface containg only host
> name
> and /etc/hosts containg IPaddress and host name.
For Solaris 10 don't forget the /etc/ipnodes file as well.
> > 19) What is /proc filesystem?
> /proc is known as window to system because it shows
> all runtime parameters of system.
Process file system
> > 22) The hard disk, which has already been backed
> up
> > completely, has crashed, how would you restore the
> > filesystems and data that were previously there?
>
> it depends u have taken backup in which format, if
> used tar to backup,
> then use #tar -xvf to restore it.
In addition to tar, there's cpio, ufsdump, and commercial software
Great Answers, R_Kumar
# 13
[[[[That's not necessary. By default, the dump contains only kernel pages, not user program pages (you can see and change the setting with 'dumpadm'). So that's normally only a fraction of the memory. Further, the dump is compressed, so even then it doesn't have to be too large.]]]]
Right. But the point is that the smaller your physical memory size is, the larger swap you need...
# 14
Corrections -- that came out of somewhere unknown :(
Smaller RAM size, you'd end up needing more swap to compensate for lack of physical memory (in order to run large apps).
So if you have 1 Gig RAM on a server and wanna run an oracle SID with 1GB SGA, you'd need a swap at least same size as RAM (or drill down to how much you need).
Same app on a system with 8GB or RAM, you don't care about swap size so much, just so long as it can hold your dump image.
# 15
What a great thread!I cannot believe that someone posted his homework here.I cannot believe that someone actually took the time to answer it, and some of them answered incorrectly...I can believe you guys correcting it, though :)
# 16
You'll notice that the answers came much too late for his homework to be turned in on time :)
# 17
[[[You'll notice that the answers came much too late for his homework to be turned in on time :) ]]]
Give the boy/girl a break willya?
At least he/she knew where to go looking. That's a great start -- most folks won't know where to search. Only advise to the original poster is to actually try and use the search features of such discussion board. That way we tend to learn "more" than what we wanted (usually a good thing).
This kinda atttitude (RTFM type) drives away people from the *nix family. We should be more encouraging and understanding (...but not to the extent of doing someone's homework for them)
# 18
Corrections -- that came out of somewhere unknown :(
Smaller RAM size, you'd end up needing more swap to compensate for lack of physical memory (in order to run large apps).
So if you have 1 Gig RAM on a server and wanna run an oracle SID with 1GB SGA, you'd need a swap at least same size as RAM (or drill down to how much you need).
Same app on a system with 8GB or RAM, you don't care about swap size so much, just so long as it can hold your dump image.
===========
Actually, you don't need any swap at all - if you have enough RAM for the apps you are running. Dumps can be sent to some otherwise unused piece of disk using dumpadm.
The machine this forum is running on has no swap. 8 Gigs of RAM and about 3 Gigs to spare. No swap. Works just fine. In most cases if you need swap, you should add more RAM. Disk is thousands of times slower than RAM.
# 19
[[[Actually, you don't need any swap at all - if you have enough RAM for the apps you are running. Dumps can be sent to some otherwise unused piece of disk using dumpadm.]]]
I don't doubt that at all...but there are older applications that absolutely demand dedicated swap space -- and you'd need to allocate swap in such cases. Like i mentioned -- swap == very slow RAM