- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- No banner for non-interactive sessions !!
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
Forums
Discussions
Discussions
Discussions
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
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
07-24-2007 05:55 AM
07-24-2007 05:55 AM
How can we avoid banner for non-interactive logins. I got a script scheduled in cron which does 'su - somusr -c script > testfile'.
The output gathers banner ie., Copyright stuffs...and atlast collects the output of the script. How can I avoid getting such 'Copyright..Stufffs', and just my script output..
-- WH
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2007 06:06 AM
07-24-2007 06:06 AM
Re: No banner for non-interactive sessions !!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2007 06:28 AM
07-24-2007 06:28 AM
Re: No banner for non-interactive sessions !!
Also, if you don't need the additional environment variables of the new user being su'ed to, then you can leave off the dash portion of the su command. I believe it shouldn't read the /etc/profile when logging in.
Otherwise, if your output file has the same number of lines, then you can add "tail -xxx " into your output line to chop off the header of the banner.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2007 07:47 AM
07-24-2007 07:47 AM
Re: No banner for non-interactive sessions !!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2007 07:54 AM
07-24-2007 07:54 AM
SolutionComment out the string
cat /etc/copyright
in /etc/profile and you'll get what you want.
If you want to see this in interactive sessions, you'll have to analize additional conditions.
HTH
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2007 08:20 AM
07-24-2007 08:20 AM
Re: No banner for non-interactive sessions !!
It's best to work with what the OS gives you. If you change the OS files, a patch can quickly break you again.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2007 08:22 AM
07-24-2007 08:22 AM
Re: No banner for non-interactive sessions !!
First option remove "-" between su and somusr
'su somusr -c script > testfile'
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2007 08:28 AM
07-24-2007 08:28 AM
Re: No banner for non-interactive sessions !!
Strictly speaking, you cannot/should not remove the copyright message. You *can* however reduce it to an officially sanctioned two-sentence note. See Technical Knowledge Base ID # emr_na-c00932256-1 .
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2007 09:26 AM
07-24-2007 09:26 AM
Re: No banner for non-interactive sessions !!
Most commonly done where the umask is set differently for certain users like Oracle.
It can't be done to prevent the banner from displaying since that is called from /etc/profile.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2007 06:50 PM
07-24-2007 06:50 PM
Re: No banner for non-interactive sessions !!
Please check the file /etc/profile. All options are there. If you dont want the "Copyright info" please block the line
# cat /etc/copyright
Thanks & Regards
A. Aashique
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2007 07:56 PM
07-24-2007 07:56 PM
Re: No banner for non-interactive sessions !!
I was looking exactly what Juan said, and agreed not to remove 'copyright'file.
Closing this thread...
-- WH