IBM s/390 manual Ultrabay, Using a second Linux hard disk, # cat /proc/partitions

Page 52

5.5 Ultrabay

ThinkPad A21 and A22 units have a “bay” that can hold a CD-ROM drive, or a diskette drive, or a second hard disk drive—but only one at a time. Current Windows operating systems permit the user to change these devices while the system is running. We were unable to make clean (without side effects) changes under Linux, while Linux was running. We found it was easier to shut down Linux, let the ThinkPad power down, and then swap devices in the Ultrabay. Linux detected the new device correctly when it was restarted.

5.5.1 Using a second Linux hard disk

The preparation and use of a second hard disk is discussed in “Ultrabay” on page 42. After it was available, we created three 3390-1 work volumes on the second hard disk. The following FLEX-ES commands, issued from a Linux Terminal window, will do this:

The ckdfmt commands take some time to run because both write the complete emulated 3390 volume. The -nflag in ckdfmt prevents a verification pass to read the formatted data just written. These commands do not perform S/390 operating system initialization. After OS/390 is running, we will need to use ICKDSF to initialize the volumes.

We obtained a second 32 GB hard disk drive (IBM part number 08K9511), along with the mounting tray (IBM part number 08K6068) needed to use it in the Ultrabay. We removed the CD-ROM drive and installed the second hard disk while the ThinkPad was turned off. We turned power on and let Linux boot. We then determined the Linux identity of the second drive:

#cat /proc/partitions

major

minor

#blocks

name

(.... more data .....)

3

0

 

hda

 

3

1

nnnnn

hda1

 

3

2

nnnnn

hda2

 

..

..

....

....

 

22

0

31253040

hdc

0 0 0 0 0 0 0 0 0 0 0

The first hard disk (internal in the ThinkPad) is /dev/hda; looking at the above listing, we see a second hard disk as /dev/hdc. This drive (as expected for a new disk) had no partitions. (We do not know why Linux selected hdc instead of hdb, which would logically be next in sequence.)

We decided to create two file systems on the second hard disk. One would be about 2 GB and use mount point /holding. The other would use all the remaining space and have mount point /s391. We intended to use /holding for compressed tar images (created as backups) and other temporary files and we might have considerable creation/deletion activity in this file system. The /s391 file system would be solely for emulated S/390 volumes. Using two file systems seemed to reduce the chances for significant fragmentation of emulated volume files.6

We also noted that IBM, like most other manufacturers, uses decimal numbers to describe disk capacity (1M = 1,000,000) while Linux utilities typically use power-of-two numbers (1M = 1,048,576). Using Linux numbers, the capacity of the disk was about 29 GB.

6We may have been too sensitive about fragmentation. Experienced Linux users claim there are practically no fragmentation effects in normal Linux file systems. However, they admit that FLEX-ES operation (57 KB reads or writes when emulating a 3390) is not typical Linux I/O. We felt that disk I/O may be the weakest point of ThinkPad/EFS performance and felt that avoiding fragmentation might help performance. The author welcomes any measurement data (on an EFS system) that may help resolve this issue.

42S/390 PID: ThinkPad Enabled for S/390

Image 52
Contents ThinkPad Enabled for S/390 Bill OgdenPage International Technical Support Organization First Edition October Contents Shutting down Index Vi S/390 PID ThinkPad Enabled for S/390 Special notice AuthorIBM trademarks Comments welcomeIntroduction Purpose of this redbook ThinkPad/EFS systemsFLEX-ES Linux Positioning with other small S/390sThinkPad/EFS hardware used Terminology System and Linux installation Disk planningDifferences Linux installation ThinkPadPartition Manually Partition Mount Point Device Requested Actual Type PurposeDevice Partition Type Default Boot 12.17.210255.255.255.0 12.17.150Gnome Installation notes Monitor Setup IBM 9513 T55A TFT No clock chip 24 bitSelect Start X automatically # df -h# ps -ef grep xinetd Etc/xinetd.d # vi telnet# kill -s USR1 pidnumber PID number for xinetd 14 S/390 PID ThinkPad Enabled for S/390 FLEX-ES and OS/390 installation FLEX-ES Brief introductionPC Processor in ThinkPad Page Installation Installing the FLEX-ES license key OS/390 AD systems Next stepsAD systems # mkdir /s3912 OS/390 on CD-ROM Basic CD-ROM formats3 OS/390 device configuration FLEX-ES formatsInstallation tasks Unzipping and installing Awsckd CD-ROM filesAn unzip program Mount /dev/cdrom /mnt/cdromMinor problems File ownershipVolume in two separate zip files Files unzip in wrong orderFLEX-ES Operation FLEX-ES system and resource definitions CommentsBuilding a shell script $ cd /usr/flexes/rundir# resadm -s R10A.rescf $ resadm -r$ sh shos Flexes ipl a80 0a82cs Terminal Solicitor IPL OS/390=stor Operation and use User terminal connection11.42.47 A80,8Linux TN3270 Iodf requirementsSystem performance monitors Rmf5 TCP/IP for OS/390 Shutting down # resadm -T# resadm -k # exit36 S/390 PID ThinkPad Enabled for S/390 Additional Topics Basic debugging Security Operating Systems Messages consoleServer memory Vmstat command Importance of Linux swapping CPUUltrabay Using a second Linux hard disk# cat /proc/partitions Second disk planning Partition Mount Size Use Disk layout AD systemDevice Volser Addr Use FLEX-ES FakeTape on OS/390 Alternative method560 222222Multi-system setup X3270 client $ x3270 -model 3 -keymap pc -port tn3270 localhost$ x3270 -model 3 -keymap pc -port tn3270 localhostt91f Function Keys UsedRemote resources # cd /usr/lib/X11/app-defaults # cp X3270 X3270old# vi Disk caches System BWrites Cache Hits Tuning cachesize FSI Channel AdaptersScsi adapter for the ThinkPad Backup and restore considerationsDisk fragmentation Using tar to back up S/390 volumes $ tar -cvzf /holding/OS39RA.tarz /s390/OS39RAUsing tar and ftp $ cd /usr/flexes/rundir $ sh buOS39RAc16 S/390 identification CD-RW driveDisplay PSW and registers RAS discussionVerify ckd disk Linux windowsInstalling FLEX-ES upgrades ThinkPad power controlUseful Linux commands Common commandsMultiple consoles, sessions, screens Text editors62 S/390 PID ThinkPad Enabled for S/390 Frequently asked questions 64 S/390 PID ThinkPad Enabled for S/390 Frequently asked questions 66 S/390 PID ThinkPad Enabled for S/390 Frequently asked questions 68 S/390 PID ThinkPad Enabled for S/390 Appendix A. FLEX-ES definition listings Basic definitions for a single HDDShell script for a single HDD Definitions for two HDDs Shell script for two HDDs Appendix B. FLEX-ES parameters System definitionsCpu0 Cpu1 Cpu2 Resource definitions Emulated control unit typesEmulated device types Typical resource definitionsCKD disk resources Terminal resources Tape resources LAN resourcesCloned devices Resadm command Common rulesCLI commands 710 Altcons Flexes mount A90 S390/WORK01560 Home/tape3 84 S/390 PID ThinkPad Enabled for S/390 Special notices 86 S/390 PID ThinkPad Enabled for S/390 How to get IBM Redbooks IBM RedbooksReferenced Web sites Other resourcesIBM Redbooks collections Index Pipe Port Power control Terminal logo Terminal Solicitor 16, 18, 31, 39, 65 92 S/390 PID ThinkPad Enabled for S/390 Partners in Development ThinkPad Enabled for S/390 Page Page ThinkPad Enabled for S/390 System setup AD CD-ROM use System operation