DevOps

Thursday, 30 September 2010

What is the difference between nfs version 2 and nfs version 3?
answer :- nfs 2 default 8kb transfer rate, it did not check the authentication at the time connection client wants to access
Unauthorized file it shows error messages like write error read error nfs 3 32 kb transfer rate. It check at the time connection acl support
What is rpc?
Answer:- remote procedure call Solaris used for transaction in nis
Answer:- remote procedure call The application will cause the code to be executed in remote host and return the value back to the application. Until that time, application will be suspended. The RPC is synchronous kind.
What is jass?
Answer :- The Solaris Security Toolkit, formerly known as the jumpstart Architecture and Security Scripts (jass) toolkit, lprovides a flexible and extensible mechanism to harden and audit Solaris operating systems (oss)
How do you boot from a network with jumpstart?
Answer:- ok boot net-install (for install the OS in client system)
Ok boot net to boot client system from network
Answer:- jumpstart hand off installation, like windows ghost.
What is jumpstart?
Answer:- By using jumpstart we can install OS at a time on multiple systems, by this we can save the time this id done by keeping OS dump in a system, from this system we can install the OS
For this, the system architecture should be same.
How do you boot from CD-Rom
Answer:- boot cdrom booting from cdrom boot net booting from network card
Answer:- command boot crfrom s we can use this command
What does init 0 do?
Answer:- init 0 is ok boot prom level
What does init 5 do?
Answer:- init 5 system halt mode
Answer:- shutdown
What does ndd do?
Answer:- Several of the network settings discussed in this artic are configured using the ndd command. It is used to examine and set kernel module parameters, namely the Transmission Control Protocol Internet protocol (TCP/IP) drivers Most kernel parameters accessible through ndd can be modified without rebooting the system. To see which parameters are available, use the following ndd commands.
Ndd dev arp
Ndd dev icmp
Ndd dev ip
Ndd dev tcp
Ndd dev udp
What is etc system for?
Answer:- etc system is a kernel configuration file The etc system file is the control file for modifying which modules and parameters are to be loaded by the kernel at boot time. By default, all lines in this file are commented out.
Modifying the kernel’s behavior (or configuration) requires editing the etc system file. Altering this file allows you to modify the kernel’s treatment of loadable modules as well as to modify kernel parameters for some performance tuning
What is an alternative to the top command on Solaris?
Answer:- prstat
What is OBP and how do you access it?
Answer:- open boot Prom this is 0 run level in Solaris stop + A or in command mode init 0
How do you get system diagnostics information?
Answer:- dmesg
How do you view shared memory statistics?
Answer:- vmstat –S
Answer:- As said above, vmstat –S and you can check the shared memory with ipcs –a
How do you create a Solaris package?
Answer:- pkgadd –d dir host
What does the pkgadd command do?
Answer:- it used for Software installation like third party tools
What is rpc why do I need it?
Answer:- RPC is simply known as Remote Procedure call this is the fundamental in NFS (Network File System)
Difference between NFS version 2 and Fns version 3?
Answer:- NFS version 2 supports 8Kb transfer rate, client can access unauthorized file they give errors
NFS Version3 supports 32 kb transfer rate, first check the permissions after that they give connection permission
What is OBP and how u r going to access it?
Answer:- Open boot Prom stop + A or init 0
How can you set EEPROM settings from Solaris?
Answer:- using eeprom command
Tell me some of the differences between Solaris and sun OS
Answer sun OS is BSD based
Solaris is used system V kernel
Security point of view, what’s there in NIS+ than NIS?
Answer :- NIS =Centralized domain
NIS+=centralized and multiple domains as well as used as ADS in windows server
Answer :- NIS+ means to control centralized domain like ADS
Nis means it is a centralized domain used as single domain
If you have forgotten the root password for a server, how do you get back in?
Answer :- boot net –S
Mount/dev dsk cotdos0 a
Cd a etc
Term=vt100
Export TERM
Vi shadow
//remove passwd field after save the file
Cd/
Umount/a
Sync
Init 6
You can receive e-mail, but when u try to send e-mail u can’t send any what is wrong?
Answer :- problem may be in RELAY ONS lookup
Answer :- The problem can be with the outgoing port number used.
Answer :- The SMTP (Simple Mail Transfer Protocol) is may not be run.
If you have multiple Ethernet interfaces, how do you keep it from routing between them?
Answer :- touch etc notrouter
What is uadmin and what does it do?
Answer :- uadmin is command control for basic administrative functions
How would you truncate a log file that is growing too large if you don’t have space to compress it or to move it somewhere else? How would you do it?
Answer :- cp dev null File Name
When you ping server and ping server domain name you get different results why?
Answer :- If you give ping hostname the server will give the result from etc hosts file if you give ping hostname domain name then I will search through internet.
Answer :- if your are pointing to the DNS server why you need to add it in a etc hosts
If you are not able to ping through hostname just type dns in etc nsswitch conf file if you try to access through hostname it read the nsswitch. Conf file this file will point to dns server
How do you give a user access to an application or program that needs to run as root without giving them the root password?
Answer : Update the etc sudoers with a sudo rule.
Answer :- write RBAC (Role Based Access Control) rules for that specific program or application
If fsck is running one thind u should not do what’s that?
Answer :- fsck is a useful command to bring back a corrupted file system back into working condition one important thing u should note while using this command is that never never fsck on a mounted file system and while it is running never try to restart the system
If you mistype a password how do you clear it out to retype the password again?
Answer :- clear password filed in etc system file
Answer :- if you are in the middle of typing a Solaris Unix password and you fat finger it Ctrl U& will clear the incorrect text you have entered and you can immediately retype the entry while at the same prompt
If you can ping a server but can’t telnet or ssh to it what wrong?
Answer :- if service not enable the server uncomment tcp ssh service in etc inetd conf
You can ping servers on the subnet your workstation is on, but not other subnets why
Answer :- need to update the routing table with a route to the subnet in question route add
Suppose if u want to reconfigure the kernel then how you are going to do?
Answer :- touch reconfigure
Boot –r
What are the files in /etc directory?
Answer :- The files in /etc directory are all configuration files
Answer :- The files in /etc are all binary executable files usually required for system administration.
Answer :- etc directory contains configuration files of all the services.
What is the main advantage of creating links to a file instead of copies of the file?
Answer :- The main advantage is not really that it saves disk space (though it does that too) but, rather, that a change of permissions on the file is applied to all the link access points. The link will show permissions of irwxrwxwx but that is for the link itself and not the access to the file to which the link points. Thus if you want to change the permissions for a command, such as su , you only have to do it on the original. With copies you have to find all of the copies and change permission on each of the copies
Etc default login etc system
Which directory contain run level control scripts?
Etc rc2 d etc init d etc rc3 d usr bin
Which command show the patch installed in the system?
Patchadd –p showrev –p showpatch patchlist
What are the advantage of having a virtual file system?
Large capacity volumes increased file system size performance enhancement backup becomes easy
Which file is used to define default run level for init process at booting time?
Etc ttyyab etc ttyadm
Etc inittab etc profile
Which command shows kernel parameters and and driver module information?
Sysconfig prtconfig dfmesg prtconf
A multiuser operating system is one in which?
Many users can work simultaneously many processes can work simultaneously
A large number of users can be created A number of user home directories can be created
What is true about software packages?
It is group of files directories they are gouped to form clusters
It is standard way of delivering software in Solaris They can be installed using pkgadd command.
What type of names are used for administering disk driven in Solaris environment?
Physical logical Virtual disk instance
What is the command to check the system configuration (ex Memory size Hard disk capacity No of Processor?
Answer cfgadm –a
What is difference between Process and Daemon?
A daemon is a software process that runs in the background (continuously) and provides the service to client upon request
Server process run runs one time when called by a daemon Once done it will stop For example telnetd (in telnetd) or ftpd called from kinetd inetd daemon
How do you determine which Run Level the system is running?
Who
How will you add a virtual IP address to a server. Given the interface hme0/eth0/qe0 and IP 10.76.176.1?
#ifconfig qe0:1 plumb
#ifconfig qe0:1 10.10.1150 up
What is sticky bit?
When this is set on a directory only the file in that directory can be removed or renamed if:
a user owns the directory
User owns the file
Super User
How many different kill signals are there?
Ans :- 47
EXIT HYUP INT QUIT ILL TRAP ABRT EMT FPE KILL BUS SEGV SYS PIPE ALRM TERM USR1 USR2 CLD PWR WINCH URG POL STOP TSTP CONT TTIN TTOU VTALRM PROF XCPU XFSZ WAIATING LWP FREEZE THAW CANCEL LOST XRES RTMIN RTMIN+1 RTMIN+2 RTMIN+3 RTMAX-3 RTMAX-2 RTMAX-1 RTMAX
What setting determines the default permissions for files and directores?
Ans umask
How can you come to the home directory?
Ans cd $Home
How can we find RAM size in solaris server?
Ans Use this command
# psrinfo grep memconf
How to do see the processor information?
#psrinfo
#psrinfo-v to see which processor are online and offline
How to change processor operation status?
#psradm –a –n to set all processor online
#psradm –f 2 3 –make processor 2 and 3 offline
How to make processor 4 offline?
#psradm –f4 offline
How to make processor 3 online?
#psrinfo –V to see the status
#psrinfo –a 3 online
How to see the kernel version and supported by it?
#isainfo
How to see the default boot device from the boot prom #setenv boot-device disk Boot-device=disk?
#reset-to make the changes
How to see all the information of the hardware related from bootprom?
#banner or #prtconf
How to see the physical disk connected to the system?
#probe-scsi
How to see all pci slots?
#probe-pci-slots
Or
#probe-pci-all
How do you check your loop back or network devices ok test net?
How to check the clock devices?
Ok netwatch-clock
How to set environment variable in NVRAM #invalias /pci—rarp –to set scsi for booting of client?
#nvalias net dhcp – to boot from dhcp
#nvunalias net – remove the alias
How to configure newly attached hardware?
#devfsadm Or
#drvconfig
What are raid0, raid1 and raid5?
How to create state database replica?
#metadb
How to see the state bases?
#metadb
How to change the default level from 8kb to 4kb?
#metadb -a -f –l 4096 c0t0d0s1
How to create 2 database replicas?
#metadb –a –f –c 2 c0t0d0s1
How to create raid 0 concatination?
#metainit d0 2 1 c0t0d0s1 1 c0t1d0s1
How to see the meta device information?
#metastat
Newfs /dev/md/rdsk/d0
Mount /dev/md/dsk/d0 /nav
How to differentiate concatenation and strippong?
when used metastat command stripping with show an interlace value 32kb this shows it is striped.
How to create raid 0 stripping?
#matainit d1 1 2 c0t0d0s1 c0t0d0s2
#metastat
#newfs /dev/md/rdsk/d1
#mount /dev/md/dsk/c1 /naveen
How to clear metadevices?
#metaclear d0
#metaclear d1
How to create mirroring raid –l?
#metainit d1 1 1 c0t0d0s1
Metainit d2 1 1 c0t0d0s2
Metainit d3 –m d1
Metattach d3 d2
Metastat
How to create stripe with parity?
#metainit d1 – raid5 c2t0d0s0 c0t0d0s0 c0t2d0s0
Metastat
Newfs /dev/md/rdsk/d1
Mount /dev/md/rdsk/d1 /naveen
How to grow the size of the volume?
#growfs –M /naveen c0t0d0s1
How to create raids using volume manager?
#vxassit –g rootdg make vo101 20g
#newfs /dev/vx/rdsk/rootdg/vo101
#mount /dev/vx/dsk/rootdg/vol101 /naveen
b) vxassit –g rootdg make vo102 20g layout=stripe st_width=32
#newfs /dev/vx/rdsk/rootdg/vo102
#mount /dev/vx/dsk/rootdg/vo102 /naveen
c) vxassit –g rootdg make vo103 20g layout=mirror
newfs /dev/vx/rdsk/rootdg/vo103
mount /dev/vx/dsk/rootdg/vo103 /naveen
d) vxassit –g rootdg make vol4 20g layout=raid5.nologs
newfs /dev/vx/rdsk/rootdg/vol4
mount /dev/vx/rdsk/rootdg/vol4
How to print plexes , subdisk , volumes?
Vxprint –pt – for plexes
Vxprint –st subdisk
Vxprint –vt volumes
How to increase the size of the volume?
Vxassit –r rootdg growby vol01 20g
/usr/lib/fs/fsck –F ufs –M /naveen /dev/vx/rdsk/rootdg/vol01 40980 (offset volue by typing the vxprint –vt command)
What is the top command used for its lists all the processes with the process id Cpu utilization and idle cpu Memory utilization and idle memory?
Swap utilization and ideal swap application using maximum cpu utilization with pid
What is lofs used for?
Lofs list open files is used for to check a problem encounter with a file or process
What is the use of truss command?
Trace system call for every running file
Whats are the fields in vfstab ?
Mount device-raw device for fsk-mountpoint-filesystem-fsckcheck-mount at boot and it contain all the mounted filesystem
How to break root password ?
#ok boot cdrom –s
TERM=ansi
Export TERM
Mkdir /naveen
Mount /dev/dsk/c0t0d0s0 /naveen
Vi /naveen/etc/passwd
Root:KHGHGHGGFG:-remove this junk passwd
Wq!
Reboot it logins with out asking for password
Password – enter new password
How to create a user ?
useradd –u uid –g gid –d /export/home/naveen –m –s /bin/sh naveen
Whats are the files which maintain user information?
/etc/passwd
/etc/group
/etc/shadow
Fields in /etc/passwd ?
user-passwd-uid-gid-homedirectory-shell
Fields in /etc/group ?
groupname-gid
Fields in /etc/shadow ?
username:encrypted passwd min-max-lastchange-warn-expire
How to create a quotas?
cd /export/home
Touch quotas
Chmod u+rw quotas
Edquota naveen
Soft=5000 hard=6000 inodes=5000 inode=5500
Quotan –v /export/home
Repqupota –v /export/home or quota –v naveen to see quota
How to create a nis master?
Domain name sun.com
Echo sun.com etc default domain
Vi etc hosts
Sun1 192.168.0.1
Sun2 192.168.0.2 add all the host connected to the network
Wq
Cp etc nsswitch. Nis etc nsswithc.sonf
Vi etc nsswitch.conf
File nis-add this entry
Wq
Cd vary p
Ypinit-m master server
Enter host 192.168.0.1
Stop at errors say no here
Yes-yes-yes
Cd vary p
User/lib/netsvc/yp/ypstop
/usr/lib/netsvc/yp/ypstart
Here you can see all the deamon get restarted
Which command display the default nis server ?
Ypwhich
Which command will display all the master and slave servers ?
Ypcat –k ypservers
How to see the nis users ?
Ypeat passwd
What are the deamons for nis master ?
Ypserv ypbind ypxfrd rpc.ypassword rpc.ypupdates
How to create nis slave server (192.168.0.2) ?
Vi/etc/host
Sun 192.19\68.0.1 master server ip
Wq
Cp etc nsswitch.nis etc switch.conf
Vi nsswitch.con
Files nis
Wq
Domainname sun.com
Echo sun.com etc defaultdomain or to maintain more security vary p ypservers
Cd vary p
Ypinit –s sun1 (master server)
Yes give master server ip or hostname
Error say no
Yes-yes
Cd var up if u u in that directory then its okay
Usr lib netsvc yp ypstop
Usr lib netsvc yp ypstart
Ypserv ypbind
Ypwhich-will display master and slave servers
Ypcat-k ypservers-list master and slave server
What are the daemon for nis slave server ?
Ypserv ypbind
Who to see nis user from the slave ?
Ypcat passwd

No comments:

Post a Comment