Explore topic-wise InterviewSolutions in Current Affairs.

This section includes 7 InterviewSolutions, each offering curated multiple-choice questions to sharpen your Current Affairs knowledge and support exam preparation. Choose a topic below to get started.

1.

How Do You Differentiate The Files /etc/lvmtab And /etc/lvmtab_p? And How To Read Lvmtab Files?

Answer»

/etc/lvmtab and /etc/lvmtab_p in HP-UX are binary files and they can be READ using the strings COMMAND like

strings /etc/lvmtab

strings /etc/lvmtab_p

the above SHOW the Volume groups by name and the member PVs (physical volumes) of that VG.

While /etc/lvmtab keeps the ENTRIES for VG version 1.0 Volume Groups, /etc/lvmtab_p contains the entries for Version 2.x Volume Groups. Version 2.X volume groups had been introduced in HP-UX 11.31 that is 11iv3.

/etc/lvmtab and /etc/lvmtab_p in HP-UX are binary files and they can be read using the strings command like

strings /etc/lvmtab

strings /etc/lvmtab_p

the above show the Volume groups by name and the member PVs (physical volumes) of that VG.

While /etc/lvmtab keeps the entries for VG version 1.0 Volume Groups, /etc/lvmtab_p contains the entries for Version 2.x Volume Groups. Version 2.X volume groups had been introduced in HP-UX 11.31 that is 11iv3.

2.

How To Start A Process In A Particular Prm Group And How To Make The Process Move To A Different Prm Group?

Answer»

A USER can start his process or move his started process to a PRM group to which he belongs to as per the PRM configuration file.

If the user has an access to a PRM group, he can start his process in that PRM group using the COMMAND prmrun as shown

$prmrun –G< PRM_Group> < Application Options>

If he is a member of the other PRM group, then he can also move his RUNNING or started process to another PRM group with prmmove command as below.

$prmmove –g< PRM_Group> -p | -g< Process Group ID> | -U< User ID>

A user can start his process or move his started process to a PRM group to which he belongs to as per the PRM configuration file.

If the user has an access to a PRM group, he can start his process in that PRM group using the command prmrun as shown

$prmrun –g< PRM_Group> < Application Options>

If he is a member of the other PRM group, then he can also move his running or started process to another PRM group with prmmove command as below.

$prmmove –g< PRM_Group> -p | -g< Process Group ID> | -u< User ID>

3.

If Prm Is Enabled And Configured, How To Display In Ps Command Which Pset Group A Process Belongs To?

Answer»

This can be seen using the option –z of the ps command, which with other things being displayed WOULD also show the PSET (processor SET) group in which the process is executing.

# ps -fzu haydes

UID PSET PID PPID C STIME TTY TIME COMMAND

haydes 0 20320 1 220 19:28:33 ? 6:23 itDB

haydes 1 20321 1 255 19:28:33 ? 6:45

quarryDB haydes 0 20319 1 0 19:28:33 ? 0:05 comp-it3

haydes 1 20323 1 255 19:28:33 ? 6:43 rdr_quarry

This can be seen using the option –z of the ps command, which with other things being displayed would also show the PSET (processor SET) group in which the process is executing.

# ps -fzu haydes

UID PSET PID PPID C STIME TTY TIME COMMAND

haydes 0 20320 1 220 19:28:33 ? 6:23 itDB

haydes 1 20321 1 255 19:28:33 ? 6:45

quarryDB haydes 0 20319 1 0 19:28:33 ? 0:05 comp-it3

haydes 1 20323 1 255 19:28:33 ? 6:43 rdr_quarry

4.

How Can You Test If The Syslog Is Logging Messages To /var/adm/syslog/syslog.log?

Answer»

This can be tested using sending a small logger message to syslogd using the command shown as below.

#logger –t hi HELLO

Logger sends a message to syslog and if syslog is WORKING properly a line should GET ADDED to /var/adm/syslog/syslog.log as showing “hi: hello”

This can be tested using sending a small logger message to syslogd using the command shown as below.

#logger –t hi hello

Logger sends a message to syslog and if syslog is working properly a line should get added to /var/adm/syslog/syslog.log as showing “hi: hello”

5.

How To See The Size Of A Disk Or A Lun In Hpux?

Answer»

Command diskinfo can be used for the same with the RAW device special file of the DISK device to see the size of the disk /LUN as SHOWN below.

#diskinfo –b /dev/rdsk/cXtYdZ – SHOWS Size in KB

#diskinfo –b /dev/rdisk/disk14 | awk ‘{print $1/1024/1024}’ – Shows Disk Size in GB

Command diskinfo can be used for the same with the RAW device special file of the Disk device to see the size of the disk /LUN as shown below.

#diskinfo –b /dev/rdsk/cXtYdZ – Shows Size in KB

#diskinfo –b /dev/rdisk/disk14 | awk ‘{print $1/1024/1024}’ – Shows Disk Size in GB

6.

How To See Without Use Of Glance The Top 20 Processes In Sorted Order Of Memory Utilization?

Answer»

USE the COMMAND:

UNIX95= ps -ef -o “user,vsz,pid,args,comm” | sort -RN –k2 | head -n 20

Use the command:

UNIX95= ps -ef -o “user,vsz,pid,args,comm” | sort -rn –k2 | head -n 20

7.

How To See Without Use Of Glance The Top 20 Processes In Sorted Order Of Cpu Utilization?

Answer»

Use the command:

UNIX95= ps -e -o “user,pcpu,CPU,ARGS,comm” |sort -rn -K2 |head -n 20

Use the command:

UNIX95= ps -e -o “user,pcpu,cpu,args,comm” |sort -rn -k2 |head -n 20

Previous Next