Anda di halaman 1dari 6

AS/400 Command Line Commands - Support

http://wiki.rjssoftware.com/wiki/index.php/AS/400_Command_Line_...

AS/400 Command Line Commands


From Support

Contents
1 Caution 2 Things To Know 3 Command Line Length 4 Displaying various system values: 5 To Display System Operator Messages 6 To Display Session Job Log 7 Library and Library List Commands: 8 Output Queue and Report Commands 9 Viewing Directories and Files on the IFS (Integrated File System) 10 Checking a User Profile 11 FTP Server Commands:

Caution
This article is designed to help people learn some basic commands on the IBM iSeries. Please note that not every user has the security to run all of the commands listed below. Please make sure that you have permission to make any changes to your system before doing so. RJS Software Systems does not accept any responsibilty for lost information or data due to using any of our Knowledge Base Articles.

Things To Know
Help Pressing <F1> while the cursor is on a message, command or a value will often bring up a help screen to give you information on that message, command or value. PROMPT Pressing <F4> after typing in a command will allow you to prompt that command to see what values can be passed to it. It will display all available parameters and acceptable values for those parameters. SECURITY As stated above: Please note that not every user has the security to run all of the commands listed below. Please make sure that you have permission to make any changes to your system before doing so. RJS Software Systems does not accept any responsibilty for lost information or data due to using any of our Knowledge Base Articles.

1 de 6

24/02/2012 09:50 a.m.

AS/400 Command Line Commands - Support

http://wiki.rjssoftware.com/wiki/index.php/AS/400_Command_Line_...

Command Line Length


Many commands are actually longer than the one or two lines typically given in the Command Line Interface. To display a larger command line:
CALL QCMD

To display a full page command line:


CALL QCMD <F11>

Displaying various system values:


If you own any RJS Software Systems product that has a library on the iSeries, you can simply run the following command to display the OS/400 operating system version, serial number, model number and partiion (LPAR) number where the product is installed:
<LIBRARY NAME>/PRDINFO

Serial number:
DSPSYSVAL QSRLNBR

Model number:
DSPSYSVAL QMODEL

System name:
DSPNETA (press enter) Local system

OS/400 version:
GO LICPGM (press enter), option 10, press F11

AS/400 TCP/IP address:

2 de 6

24/02/2012 09:50 a.m.

AS/400 Command Line Commands - Support

http://wiki.rjssoftware.com/wiki/index.php/AS/400_Command_Line_...

NETSTAT (press enter); option 1

To find system values (the long way):


WRKSYSVAL identify value you are searching for, enter 5<ENTER> value is displayed Value for the serial number is QSRLNBR

To Display System Operator Messages


DSPMSG<F4> QSYSOPR<ENTER>

Messages are displayed

To Display Session Job Log


DSPJOBLOG

When Job Log appears, press <F10> to see a detailed log and page up from the bottom to see the most current activity.

Library and Library List Commands:


To display your current library list:
DSPLIBL

To add a library to your library list


ADDLIBLE followed by library name

To remove a library from your library list


RMVLIBLE followed by library name

To see if a library is present, enter

3 de 6

24/02/2012 09:50 a.m.

AS/400 Command Line Commands - Support

http://wiki.rjssoftware.com/wiki/index.php/AS/400_Command_Line_...

WRKLIB <library name> <ENTER>

To find the current version of a RJS Software Systems product library:


DSPDTAARA <F4> Data area name: Library: VERSION <LIBRARY NAME>

To display all the objects within a library:


WRKOBJPDM <LIBRARY NAME>

Output Queue and Report Commands


To display all output queues:
WRKOUTQ *ALL

NOTE: Helpful in checking for output queue existance To display a specific output queue:
WRKOUTQ <OUTPUT QUEUE NAME>

NOTE: You can see several queues with similar names by using the "*" wildcard NOTE: If you have the same output queue in multiple libraries, you may need to specify the library as well. To create an output queue
CRTOUTQ <LIBRARY NAME>/<OUTPUT QUEUE NAME>

NOTE: If you do not specify a library when you create the output queue, it should create it in teh QGPL library by default. To clear an output queue (deletes all spool files in the output queue):
CLROUTQ <LIBRARY NAME>/<OUTPUT QUEUE NAME>

NOTE: If you do not specify a library name, it will clear the first output queue with the matching name that it finds while searching your library list. To delete an output queue:

4 de 6

24/02/2012 09:50 a.m.

AS/400 Command Line Commands - Support

http://wiki.rjssoftware.com/wiki/index.php/AS/400_Command_Line_...

DLTOUTQ <LIBRARY NAME>/<OUTPUT QUEUE NAME>

NOTE: If you do not specify a library name, it will delete the first output queue with the matching name that it finds while searching your library list. To look at reports by owner
WRKSPLF<F4>

enter 5 by the appropriate user<ENTER>, then you can find output queue

Viewing Directories and Files on the IFS (Integrated File System)


File structure on the IFS is similar to the UNIX file system (even the commands match). All directory or file paths start with a basic / to indicate the root of the system. The rest follows basic directory structures. To access the root directory on the IFS:
WRKLNK "/" put a 5 on the folder to view its contents

To access a directory called RJSTEMP in the root of the IFS:


WRKLNK "/RJSTEMP" put a 5 on the folder to view its contents

Checking a User Profile


To look at all the user profiles:
WRKUSRPRF *ALL

To look at a specific user profile:


WRKUSRPRF <ISERIES USER NAME>

User settings of importance (primarily for the WinSpool products):


check check check check

STATUS (should be ENABLED) SET PASSWORD TO EXPIRE (should be NO) LIMIT CAPABILITIES (if *YES, we have a Notes technical document that tell them the commands they must have -- do a user class (*SECOFR indicates security officer level)

5 de 6

24/02/2012 09:50 a.m.

AS/400 Command Line Commands - Support

http://wiki.rjssoftware.com/wiki/index.php/AS/400_Command_Line_...

FTP Server Commands:


To check on FTP server status:
NETSTAT (press enter), option 3 if FTP server is running, you will see FTP-CON as an entry in Local Port and it will have a state of LISTEN

To start the FTP server:


STRTCPSVR *FTP

To end the FTP server:


ENDTCPSVR *FTP

To change FTP timeout:


CHGFTPA <F4>

NOTE: Inactivity timeout is 300 seconds (5 minutes) by default. Setting it to 0 indicates no timeout! After changing the FTP attributes, you must stop FTP server and restart

To verify that you can log on to your AS/400 FTP Server from DOS, perform the following: 1. Go to DOS prompt 2. Type FTP <IP Address> and press ENTER 3. You should then be asked for a user ID and password. If this fails or doesn't happen, there is a problem connecting to your AS/400 FTP server and our software will not work until this is resolved. Retrieved from "http://wiki.rjssoftware.com/wiki/index.php/AS/400_Command_Line_Commands" Categories: OS/400 | TBPR | Knowledge Base | How To This page was last modified on 26 December 2007, at 22:41. Web Meeting: Go

6 de 6

24/02/2012 09:50 a.m.