HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Solaris /dev/stdout equivalent for HP-UX? (NOT /de...
Operating System - HP-UX
1833738
Members
2410
Online
110063
Solutions
Forums
Categories
Company
Local Language
back
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
back
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
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
Topic Options
- 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-29-2004 09:01 AM
07-29-2004 09:01 AM
I am moving an Informix SE database from Solaris to HP. Many of the SQL scripts use a line like UNLOAD TO /dev/stdout DELIMITER "," to set a useful delimiter to use. When the SQL scripts are used the output is redirected as desired. Some scripts are used twice and output to different files for comparison. Informix SE's dbaccess won't take a variable being passed in like $SYSOUT. I talked to Informix and another admin here and I have some workarounds, but the key word is WORK; all the scripts would need to be changed. The absolute best solution would be a /dev/stdout equivalent for HP-UX. Any ideas?
Solved! Go to Solution.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-29-2004 10:14 AM
07-29-2004 10:14 AM
Solution
HP-UX doesn't have a /dev/stdout and you have probably learned a valuable lesson now. Don't never ever hardcode nothing unless you know it's supported across all possible platforms.
Here's the best I have been able to come up with, a named pipe equivalent:
mkfifo -m 666 /dev/stdout
Now start a process to grab the input of this pipe.
tail -f /dev/stdout > /var/tmp/myfile.tmp &
You should then be able to use /dev/stdout in your scripts.
The downside to this workaround is that unlike a real /dev/stdout device node; all processes which write to /dev/stdout will dump to the same pipe so that outputs from multiple processes might be interleaved.
Here's the best I have been able to come up with, a named pipe equivalent:
mkfifo -m 666 /dev/stdout
Now start a process to grab the input of this pipe.
tail -f /dev/stdout > /var/tmp/myfile.tmp &
You should then be able to use /dev/stdout in your scripts.
The downside to this workaround is that unlike a real /dev/stdout device node; all processes which write to /dev/stdout will dump to the same pipe so that outputs from multiple processes might be interleaved.
If it ain't broke, I can fix that.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-29-2004 11:14 AM
07-29-2004 11:14 AM
Re: Solaris /dev/stdout equivalent for HP-UX? (NOT /dev/tty)
Clay,
stdin, stdout, stderr: I thought they were standard when I created them years ago, but I now know better. The named pipe trick was exactly what the other admin here had suggested and I do think it will work. Thanks for the confirmation.
Chris
stdin, stdout, stderr: I thought they were standard when I created them years ago, but I now know better. The named pipe trick was exactly what the other admin here had suggested and I do think it will work. Thanks for the confirmation.
Chris
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-16-2004 12:33 AM
12-16-2004 12:33 AM
Re: Solaris /dev/stdout equivalent for HP-UX? (NOT /dev/tty)
Solution by Clay is worked well enough for a quick fix. I "wrapped" the sql scripts with a perl program to replace /dev/null with the name of a file on execution as a longer term solution.
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP