- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- ksh(korn shell) - list of environment
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
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
тАО04-03-2006 11:01 PM
тАО04-03-2006 11:01 PM
ksh(korn shell) - list of environment
with the command "set" i can set serveral options like "set -x, set -a" and so on.
i have a difficult application and i want
to debug some steps. i want to know , which
options are used by "set". with command "env" , i can't see the settings. for example, in ORACLE-SQLPLUS , i can use the command "show all" and i can see the settings.
best regards
tom
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-03-2006 11:05 PM
тАО04-03-2006 11:05 PM
Re: ksh(korn shell) - list of environment
# env
# typeset
# set
read man ksh page.
--
Muthu
- Tags:
- env
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-03-2006 11:08 PM
тАО04-03-2006 11:08 PM
Re: ksh(korn shell) - list of environment
Do a # man sh-posix and man ksh, you will find everything there.
_Arun
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-03-2006 11:26 PM
тАО04-03-2006 11:26 PM
Re: ksh(korn shell) - list of environment
when you set environments in an application you can display them with
'echo $
Put it in your program to check the current settings of the variable
HTH
Volkmar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-03-2006 11:50 PM
тАО04-03-2006 11:50 PM
Re: ksh(korn shell) - list of environment
just type "set" alone, it will display all currently set variables.
Addition stuff on shell programming in "Shells: User's Guide: HP 9000 Computers"
http://docs.hp.com/en/B2355-90046/
part III is for ksh.
antonio.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-05-2006 06:07 AM
тАО04-05-2006 06:07 AM
Re: ksh(korn shell) - list of environment
if you mean the value of options you have set with the set-command: Try
print $-
The variable '-' collect all the 'set'-flags, so:
set -x
set -e
print $-
ivx
(i -> interactive shell)
mfG Peter
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-05-2006 07:01 AM
тАО04-05-2006 07:01 AM
Re: ksh(korn shell) - list of environment
set
To see the exported variable which will be passed onto a script or process, tpye the command:
env
Since set is for the local environment, things like set -x will not apply to a script that you run normally. To trace a script, you can eithee run it with the -x option as in:
sh -x ./myscript
or add set -x to the beginning of your script. Note that in a script, functions are like new scripts so they don't inherit the -x option, so you'll have to add it to your functions.
Note that all the flags for set options are found in the variable $- where if the option has been set, the letter appears and if not set, the letter is missing. So,
echo $-
inum
means set -i -n -u and -m are all set and all others are reset.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-09-2006 06:47 PM
тАО04-09-2006 06:47 PM