- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Script addition
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-24-2009 11:19 AM
тАО02-24-2009 11:19 AM
If [[ $# != 1 ]]
then
echo ├в Test mode - Command would be: chown / chmod├в $FILENAME
else
perform chown/chmod
fi
But I am having trouble incorporating it into the script. Can someone help me with where to add this in, or know of an easier way?
Solved! Go to Solution.
- Tags:
- Test
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-24-2009 11:29 AM
тАО02-24-2009 11:29 AM
Re: Script addition
#!/usr/bin/sh
if [ $# -ne 1 ]; then
echo "ONE argument only, please"
else
echo "OK, I saw one argument"
fi
...
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-24-2009 11:33 AM
тАО02-24-2009 11:33 AM
Re: Script addition
#!/usr/bin/sh
if [ $# -ne 1 ]; then
echo "ONE argument only, please"
exit 99
else
echo "OK, I saw one argument"
fi
...
If not using one and only one argument, get the heck out of Dodge. :-)
HP-Server-Literate since 1979
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-24-2009 11:44 AM
тАО02-24-2009 11:44 AM
Re: Script addition
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-24-2009 11:48 AM
тАО02-24-2009 11:48 AM
Re: Script addition
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-24-2009 11:53 AM
тАО02-24-2009 11:53 AM
Re: Script addition
...
echo "TEST MODE - command would be: 'chown somebody ${FILENAME}'"
...
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-24-2009 12:05 PM
тАО02-24-2009 12:05 PM
Re: Script addition
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-24-2009 12:46 PM
тАО02-24-2009 12:46 PM
Re: Script addition
Please attach a TEXT file.
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-24-2009 01:08 PM
тАО02-24-2009 01:08 PM
Re: Script addition
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-24-2009 01:09 PM
тАО02-24-2009 01:09 PM
Re: Script addition
- Tags:
- missing attachment