Sponsored Content
Operating Systems HP-UX pwage-hpux-T for Trusted HPUX servers Post 302507631 by methyl on Thursday 24th of March 2011 11:00:16 AM
Old 03-24-2011
Some points.

The normal secondary delimiter in the /etc/passwd comments field is a comma. Don't try a colon - it will corrupt the passwd file. The "usermod" command should stop you creating an invalid passwd file.

Quote:
cat /etc/passwd | grep $i |
This is a dodgy construct because it can give false matches in any field. In the simple case, consider usernames called "fred", "freda" and "alfred". One extreme case would be a username called "home".
A safer version in the style of your script:
Code:
grep \^${i}: /etc/passwd |

On many O/S the "for i in <open ended list>" construct will collapse when the command line becomes too long for the CLI.


Just for interest in non-trusted HP-UX you can get all the base information for this type of script from the command:
Code:
logins -xto


Last edited by methyl; 03-24-2011 at 12:16 PM..
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

HPUX 10.20 et HPUX 11

Is there any problems of binaries compatibility between HPUX 10.20 et 11 ? (2 Replies)
Discussion started by: Olivier
2 Replies

2. HP-UX

HPUX any help

:( i got couple of weeks ago a : HP Visualize workstation , model B100. everithing is ok in the box the only problem is that i 'am not familiar with this operational sys, and i try to uninstall and see if i can get on it windows net server 64 bit. or any other 64 bit operational sys that i'll... (1 Reply)
Discussion started by: newbird
1 Replies

3. UNIX for Dummies Questions & Answers

New to HPUX

Hi, I am a SAP Basis admin recentely been asked to administer a HPUX server. Could someone recommend some good study material to learn with the Sap prespective. -carry (1 Reply)
Discussion started by: carryclare
1 Replies

4. UNIX and Linux Applications

RPM For HPUX

Hi can any tell where we can get RPM files for HPUX OS RPM file can be of any application ,it should be succesfully installed in the machine Regards Harish Kumar :confused: (2 Replies)
Discussion started by: harishkumar
2 Replies

5. Shell Programming and Scripting

Need Script to Use CPUs on a HPUX server to simulate Workload Manager on HPUX.

I am running HPUX and using WLM (workload manager). I want to write a script to fork CPUs to basically take CPUs from other servers to show that the communication is working and CPU licensing is working. Basically, I want to build a script that will use up CPU on a server. Any ideas? (2 Replies)
Discussion started by: cpolikowsky
2 Replies

6. Shell Programming and Scripting

hpux vi

Hello. I cant figure out how can i move entire row up , so it pasted on the one above at the end , or to do that for one character. In notepads,word, or some other text editors we would do that with backspace button. Example. Content of my text file is this : I am trying to do that. And... (2 Replies)
Discussion started by: tonijel
2 Replies

7. UNIX and Linux Applications

Stop samba from querying trusted domain servers

Hi, We've got a samba server running in our DMZ. Our users drag & drop files on it for vendors. Everything was working perfectly until the powers that be decided to build a trust between a couple of internal domains. Samba is now querying each server in the trust. When a user browses... (5 Replies)
Discussion started by: mph
5 Replies

8. AIX

pwage-aix for IBM AIX servers

This is the password aging script for aix just completed. So far tested and still testing on one of our aix server running 5.3.0.0. So anyway as you can see it is very similar to pwage-hpux-T the only difference on aix /etc/passwd file looks in this format. Also for this script to work you need to... (0 Replies)
Discussion started by: sparcguy
0 Replies

9. Shell Programming and Scripting

Hpux

Hello All Why is hpux is not much spoken in the unix/Linux platform. what is the disadvantes in HPUX Thanks, VJ (1 Reply)
Discussion started by: Vijaykannan T
1 Replies

10. HP-UX

From a C++ application how to find if a hpux host is in standard mode or trusted mode

is there a way for my C++ application to find out which mode the hpux OS is running in? standard mode or trusted mode. (3 Replies)
Discussion started by: einsteinBrain
3 Replies
hpux.efi(1M)															      hpux.efi(1M)

NAME
hpux.efi - HP-UX bootstrap for Itanium-based systems SYNOPSIS
DESCRIPTION
is the HP-UX-specific operating system loader utility for bootstrap. It is a native efi(4) application that can be run on the Itanium- based platform. supports the following options: Display the release and version numbers of the utility. Boot the system in tunable maintenance mode, also known as "failsafe boot" mode. This option will disregard the tunable settings and module settings in the kernel configuration, and boot with known good settings instead. Boot the system in VxVM maintenance mode, configure only the root volume, and then enter single user mode. The following commands can be given interactively from the keyboard or provided in an efi(4) file. Load a kernel object file from an HP-UX file system and transfer control to the loaded image. (Note, the operation is position-dependent). Currently, is limited to disk for booting. file can be the name of a kernel object file or the name of a kernel configuration direc- tory. The following commands can given interactively from the keyboard only after is launched. List the contents of HP-UX directories in detail. List the contents of HP-UX directories. Display the contents of the file. Change the contents of the file to string. boot Operation The operation loads an ELF kernel object file from supported HP-UX file system (HFS, VxFS). It then transfers control to the loaded image. In addition to the kernel object file, also loads persistent system-specific files from the directory and kernel configuration-specific files from the directory during operation. always assumes (the boot directory) as the current directory. For example, would actually yield: Along with this information, gives the sizes of the and segments before transferring control to it. The operation accepts several options. Note that options be specified positionally as shown in the syntax statement in the Options for the operations are as follows: Set the initial run-level for when booting the system. This run-level overrides any run-level specified in an entry in See init(1M) and inittab(4). variable=value Set the specified variable to the specified value. (No whitespace is allowed.) If variable is a kernel tunable parameter, this sets the value of that tunable, overriding the value in the kernel con- figuration being booted. value must be a decimal integer or a hexadecimal integer (with a prefix). can load only ELF object files. ll and ls Operations The and operations list the contents of the HP-UX directory. In addition to filenames, displays size and date information when used on supported HP-UX filesystems. For VxVM disks, only boot volume information can be displayed. To display boot volume information, either a relative path to or an abso- lute path can be used. setauto Operation The operation overwrites the contents of the file, with the string specified. showauto Operation The operation displays the contents of the file, See in the section. EXAMPLES
Automatic Boot This is an overview of HP-UX automatic boot processes on Itanium-based systems. When power is applied to the HP-UX system processor, or the system button is pressed, Itanium-based system firmware code is executed to verify hardware and general system integrity (see boot(1M)). After initializing the hardware, the EFI is launched. The EFI gives the user the option to automatically start any EFI appli- cation. After is launched by the EFI it looks for an file and uses its content for the boot string. Then it gives the user the option to override the sequence by pressing any key: If does not detect a key press, it initiates the sequence using the string. displays messages similar to the following on the console: If successfully locates the kernel object file, it displays the progress of loading each sections and the symbol table of the object file. Then it displays the progress of loading system- and kernel configuration-specific directories. Finally, displays the complete path to the kernel object file loaded and the size, size, and size of the load image before control is passed to the image. The loaded image then displays numerous configuration and status messages. Interactive Boot To use interactively, the user must interrupt the autoboot sequence by pressing a key or removing the file. Then interactively prompts for commands. SEE ALSO
boot(1M), hpux(1M), init(1M), efi(4), inittab(4). Itanium(R)-based Systems Only hpux.efi(1M)
All times are GMT -4. The time now is 10:41 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy