Sun Microsystems Logo
Products and Services
 
Support and Training
 
 

A  B  C  D  E  F  G  H  I  J  K  L  M  N  O  P  Q  R  S  T  U  V  W  X  Y  Z  
 
User Commandsunset(1)


NAME

 unset - removes one or more variables from the environment.

SYNOPSIS

 unset env_var [env_var] *

DESCRIPTION

 

Use the unset command to remove one or more variables you set for the environment. The variables and their associated values will no longer exist. This command can be run remotely only.


OPERANDS

 
env_var
environment variable to be removed.

EXAMPLES

 Example 1. Using unset to remove environment variables
 
 
asadmin> export AS_ADMIN_HOST=bluestar AS_ADMIN_PORT=8000 AS_ADMIN_USER=admin 
AS_ADMIN_PASSWORD=password
asadmin> export AS_ADMIN_PREFIX=server1.jms-service
asadmin> export
AS_ADMIN_HOST=bluestar
AS_ADMIN_PORT=8000
AS_ADMIN_USER=admin
AS_ADMIN_PASSWORD=********
AS_ADMIN_PREFIX=server1.jms-service
asadmin> unset AS_ADMIN_PREFIX
asadmin> export
AS_ADMIN_HOST=bluestar
AS_ADMIN_PORT=8000
AS_ADMIN_USER=admin
AS_ADMIN_PASSWORD=********

Using the export command without the argument lists the environment variables that are set. Notice the AS_ADMIN_PREFIX is not in the environment after running the unset command.


EXIT STATUS

 
0
command executed successfully
1
error in executing the command

SEE ALSO

 

export(1), multimode(1)



Go To TopLast Changed April 2004