EnderUNIX Team.


EnderUNIX İpucu

Arkadaşıma gönder , Ana Sayfa

[ Solaris ]

"Eklenen Yeni Diski sistemde kullanılır hale getirmek" - ATILIM BOY - (2005-01-13 21:01:18)   [3041]

[root@solarisim-ben /]# format
Searching for disks...done

2 Nolu disk eklendiği için o seçilir :

AVAILABLE DISK SELECTIONS:
0. c0t0d0
/pci@1f,4000/scsi@3/sd@0,0
1. c0t1d0
/pci@1f,4000/scsi@3/sd@1,0
2. c0t2d0
/pci@1f,4000/scsi@3/sd@2,0
Specify disk (enter its number): 2
selecting c0t2d0
[disk formatted]


FORMAT MENU:
disk - select a disk
type - select (define) a disk type
partition - select (define) a partition table
current - describe the current disk
format - format and analyze the disk
repair - repair a defective sector
label - write label to the disk
analyze - surface analysis
defect - defect list management
backup - search for backup labels
verify - read and display labels
save - save new disk/partition definitions
inquiry - show vendor, product and revision
volname - set 8-character volume name
! - execute , then return
quit
format>

-----------------------------------------

partition oluşturulur :

format> partition

PARTITION MENU:
0 - change `0' partition
1 - change `1' partition
2 - change `2' partition
3 - change `3' partition
4 - change `4' partition
5 - change `5' partition
6 - change `6' partition
7 - change `7' partition
select - select a predefined table
modify - modify a predefined partition table
name - name the current table
print - display the current table
label - write partition map and label to the disk
! - execute , then return
quit

partition> print
Current partition table (original):
Total disk cylinders available: 7506 + 2 (reserved cylinders)

Part Tag Flag Cylinders Size Blocks
0 unassigned wm 0 0 (0/0/0) 0
1 unassigned wm 0 0 (0/0/0) 0
2 backup wm 0 - 7505 16.86GB (7506/0/0) 35368272
3 unassigned wm 0 0 (0/0/0) 0
4 unassigned wm 0 0 (0/0/0) 0
5 unassigned wm 0 0 (0/0/0) 0
6 unassigned wm 0 0 (0/0/0) 0
7 unassigned wm 0 0 (0/0/0) 0

7 nolu bölüm seçilir ve boyut 16 GB olarak ayarlanır. Disk tek bir partition yapılmıştır ! İstenildiği taktirde boyut hesaplanarak diğer rakamlar için de partition eklenebilir...

partition> 7
Part Tag Flag Cylinders Size Blocks
3 unassigned wm 0 0 (0/0/0) 0

Enter partition id tag[unassigned]:
Enter partition permission flags[wm]:
Enter new starting cyl[0]: 0
Enter partition size[0b, 0c, 0e, 0.00mb, 0.00gb]: 16.86gb

partition> print
Current partition table (unnamed):
Total disk cylinders available: 7506 + 2 (reserved cylinders)

Part Tag Flag Cylinders Size Blocks
0 unassigned wm 0 0 (0/0/0) 0
1 unassigned wm 0 0 (0/0/0) 0
2 backup wm 0 - 7505 16.86GB (7506/0/0) 35368272
3 unassigned wm 0 0 (0/0/0) 0
4 unassigned wm 0 0 (0/0/0) 0
5 unassigned wm 0 0 (0/0/0) 0
6 unassigned wm 0 0 (0/0/0) 0
7 unassigned wm 0 - 7505 16.86GB (7506/0/0) 35368272

-----------------------------------------

Oluşturulan Partition'un map ve label'ı Disk'e yazılır :

partition> label
Ready to label disk, continue? yes

partition> print
Current partition table (original):
Total disk cylinders available: 7506 + 2 (reserved cylinders)

Part Tag Flag Cylinders Size Blocks
0 unassigned wm 0 0 (0/0/0) 0
1 unassigned wm 0 0 (0/0/0) 0
2 backup wm 0 - 7505 16.86GB (7506/0/0) 35368272
3 unassigned wm 0 0 (0/0/0) 0
4 unassigned wm 0 0 (0/0/0) 0
5 unassigned wm 0 0 (0/0/0) 0
6 unassigned wm 0 0 (0/0/0) 0
7 unassigned wm 0 - 7503 16.86GB (7504/0/0) 35358848

partition> q

-----------------------------------------

Oluşturulan partition ile ilgili bilgiler görüntülenir : (sondaki 7'ye dikkat)

[root@solarisim-ben /]# prtvtoc /dev/rdsk/c0t2d0s7
* /dev/rdsk/c0t2d0s7 partition map
*
* Dimensions:
* 512 bytes/sector
* 248 sectors/track
* 19 tracks/cylinder
* 4712 sectors/cylinder
* 7508 cylinders
* 7506 accessible cylinders
*
* Flags:
* 1: unmountable
* 10: read-only
*
* Unallocated space:
* First Sector Last
* Sector Count Sector
* 35358848 9424 35368271
*
* First Sector Last
* Partition Tag Flags Sector Count Sector Mount Directory
2 5 00 0 35368272 35368271
7 0 00 0 35358848 35358847

-----------------------------------------

Dosya Sistemi oluşturulur :

[root@solarisim-ben /]# newfs /dev/rdsk/c0t2d0s7
newfs: /dev/rdsk/c0t2d0s7 last mounted as /export/home1
newfs: construct a new file system /dev/rdsk/c0t2d0s7: (y/n)? y
Warning: cylinder groups must have a multiple of 2 cylinders with the given
parameters
Rounded cgsize up to 230
/dev/rdsk/c0t2d0s7: 35358848 sectors in 7504 cylinders of 19 tracks, 248 sectors
17265.1MB in 342 cyl groups (22 c/g, 50.62MB/g, 6208 i/g)
super-block backups (for fsck -F ufs -o b=#) at:
32, 103952, 207872, 311792, 415712, 519632, 623552, 727472, 831392, 935312,
1039232, 1143152, 1247072, 1350992, 1454912, 1558832, 1662752, 1766672,
1870592, 1974512, 2078432, 2182352, 2286272, 2390192, 2494112, 2598032,
2701952, 2805872, 2909792, 3013712, 3117632, 3221552, 3317280, 3421200,
3525120, 3629040, 3732960, 3836880, 3940800, 4044720, 4148640, 4252560,
4356480, 4460400, 4564320, 4668240, 4772160, 4876080, 4980000, 5083920,
5187840, 5291760, 5395680, 5499600, 5603520, 5707440, 5811360, 5915280,
....

-----------------------------------------

Disk çalıştırılmadan önce denetlenir vs :

[root@solarisim-ben /]# fsck -y /dev/rdsk/c0t2d0s7
** /dev/rdsk/c0t2d0s7
** Last Mounted on
** Phase 1 - Check Blocks and Sizes
** Phase 2 - Check Pathnames
** Phase 3 - Check Connectivity
** Phase 4 - Check Reference Counts
** Phase 5 - Check Cyl groups
2 files, 9 used, 17408529 free (9 frags, 2176065 blocks, 0.0% fragmentation)

-----------------------------------------

Mount edeceğimiz dizin oluşturulur, ve mount :

[root@solarisim-ben /]# mkdir /db

[root@solarisim-ben /]# mount /dev/dsk/c0t2d0s7 /db

[root@solarisim-ben /]# df -h
Filesystem size used avail capacity Mounted on
/dev/dsk/c0t0d0s0 995M 457M 478M 49% /
/dev/dsk/c0t0d0s4 5.3G 1.1G 4.2G 21% /usr
/proc 0K 0K 0K 0% /proc
mnttab 0K 0K 0K 0% /etc/mnttab
fd 0K 0K 0K 0% /dev/fd
/dev/dsk/c0t0d0s1 995M 125M 810M 14% /var
swap 2.5G 104K 2.5G 1% /var/run
swap 2.5G 16K 2.5G 1% /tmp
/dev/dsk/c0t1d0s7 17G 91M 16G 1% /data
/dev/dsk/c0t2d0s7 17G 9K 16G 1% /db

-----------------------------------------

Açılışta tekrar mount edilmesi için :

[root@solarisim-ben /]# mount | grep db
/db on /dev/dsk/c0t2d0s7 read/write/setuid/intr/largefiles/xattr/onerror=panic/dev=800017 on Wed Jan 5 21:37:14 2005

[root@solarisim-ben /]# cat >> /etc/vfstab

/dev/dsk/c0t2d0s7 /dev/rdsk/c0t2d0s7 /db ufs 2 yes -


Arkadaşıma gönder , Ana Sayfa