Re: Execute usermod command via remsh on HP UX (576 Views)
Reply
Occasional Contributor
unix_3608
Posts: 8
Registered: ‎07-05-2011
Message 1 of 3 (593 Views)

Execute usermod command via remsh on HP UX

Hi Experts,

 

I tried to execute the remsh command via remsh, it got failed. I am able to execute commands, bdf, cat..  via remsh.

 

Here I am attaching the command details I used and the error messages. Kindly let me know whether usermod will support with remsh on hp ux. current os version is 11.31 and trying to execute on different flavors.

 

for i in `cat wkh`
do
print "doing $i"
remsh $i /usr/sbin/usermod-c "Wajid Khan, Genpact SAP Basis Team" wkhan
done

 

------------------------------------------------------------

 

Error

====

# ./id
doing lccdb042
User name must be specified
Usage: usermod.sam [-p <passwd> [-u <uid> [-o]] [-g <group> [-G <group>[,<group...> [-d <dir> [-m]] [-s <shell>] [-c <comment>] [-f <inactive>] [-e <expire>] [-l <new logname>] <login>

 

 

and tried with /usr/sam/lbin/usermod.sam combination also, probing same result.

 

Thanks in Advance.

 

 

 

 

Please use plain text.
Honored Contributor
Steven Schweda
Posts: 9,084
Registered: ‎02-23-2005
Message 2 of 3 (576 Views)

Re: Execute usermod command via remsh on HP UX

Please use plain text.
Occasional Contributor
unix_3608
Posts: 8
Registered: ‎07-05-2011
Message 3 of 3 (570 Views)

Re: Execute usermod command via remsh on HP UX

Hi,

 

Thanks for extreme support. I have executed the command with with help of single quote. It was success.

 

 

Please use plain text.
The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation