<< 七月 2007 | 主页 | 九月 2007 >>

E450添加146G硬盘

资料来源:

http://kmust.org/blogs/andnet/archive/2005/08/23/add_new_disk_on_solaris_10.aspx?Ajax_CallBack=true
http://www.linuxgoo.com/2005/7130/12324242985.html

如果机器支持 hard swap ,直接将第二块硬盘接上去,然后依次执行如下命令,不用重新启动机器。

CODE:
# modunload -i 0
# drvconfig
# devlinks
# disks

如果需要重新格式化、分区、建立文件系统,就继续执行
CODE:
# format
# newfs
以下是format的一些操作记录
# format
Searching for disks...done

AVAILABLE DISK SELECTIONS:
       0. c0t0d0 <WDC WD400BB-22DEA0 cyl 19156 alt 2 hd 16 sec 255>
          /pci@1f,0/ide@d/dad@0,0
       1. c0t2d0 <WDC WD400BB-22DEA0 cyl 19156 alt 2 hd 16 sec 255>
          /pci@1f,0/ide@d/dad@2,0
Specify disk (enter its number): 1
selecting c0t2d0
[disk formatted, no defect list found]

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
        show       - translate a disk address
        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
        volname    - set 8-character volume name
        !<cmd>     - execute <cmd>, then return
        quit
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
        !<cmd> - execute <cmd>, then return
        quit
partition> 7
Part      Tag    Flag     Cylinders         Size            Blocks
  7       home    wm       0 - 19155       37.27GB    (19156/0/0) 78156480
Enter partition id tag[home]:
Enter partition permission flags[wm]:
Enter new starting cyl[0]:
Enter partition size[78156480b, 19156c, 19155e, 38162.34mb, 37.27gb]:
format> t

AVAILABLE DRIVE TYPES:
        0. WDC WD400BB-22DEA0
        1. other
Specify disk type (enter its number)[0]:
selecting c0t2d0
[disk formatted, no defect list found]
format> sa
Saving new disk and partition definitions
Enter file name["./format.dat"]:
format> q
接下来的工作就是分区了
# newfs /dev/dsk/c0t2d0s7上次被安装为 /export/home0
newfs: 建构新的文件系统 /dev/rdsk/c0t2d0s7: (y/n)? y
/dev/rdsk/c0t2d0s7:     在 19156 磁道上,16 扇区的 255 柱面的 78156480 扇区
        38162.3MB 在 737 柱面群组 (26 c/g, 51.80MB/g, 6400 i/g)
超块 (fsck -F ufs -o b=#) 备份在:
 32, 106368, 212704, 319040, 425376, 531712, 638048, 744384, 850720, 957056,
初始化柱面组:
..............
最后 10 个柱面组的超级块备份位置:
 77121984, 77228320, 77334656, 77440992, 77547328, 77653664, 77760000,
 77866336, 77972672, 78074912,

newfs: /dev/rdsk/c0t2d0s7
# mkdir /export/home0
# mount /dev/dsk/c0t2d0s7 /export/home0
# bash      
# export LANG=en
# export TERM=vt100
# vi /etc/vfstab
在该文件中加入一行:
#/dev/dsk/c0t2d0s7       /dev/rdsk/c0t2d0s7      /export/home0   ufs     2       yes     -
重起。
#init 6
 

阅读全文...

标签 :

solaris下默认FTPD的使用技巧

  • 默认情况下,solaris默认开通ftp及telnet,此服务均由inetd控制,其配置文件为/etc/inetd.conf,可注销掉相应的行对此服务进行开放或禁止!
  • solaris 8 ftp配置文件,默认放置在/etc下;从solaris 9开始,ftp配置放置在/etc/ftpd下,而且安装好OS后,服务均默认开放!
  • 若要限制root用户ftp权限,只需修改/etc/ftpd/ftpusers,注销掉root行,然后重启inetd进程便可!
  • 若要让ftp用户登陆后限制在自己当前目录下活动,可编辑/etc/ftpd/ftpaccess,加入如下一行:
    restricted-uid userid
    如:
    restricted-uid siemens alcatel ericsson  
  • 3.若要禁止ftp用户以telnet登陆到本系统中,可编辑/etc/shells,加入你要指定的shell,,当然此shell可以是一个空的不存在的shell,这样做只是为了让系统认为其合法,从而在实现此功能的前掉下不影响ftp功能!
    #more /etc/shells
    /usr/bin/bash
    /bin/sh
    /usr/lib/uucp/uucico
    /bin/csh
    /bin/ksh
    /bin/tcsh
    /sbin/sh
    /bin/sh
    /sbin/nologin
    #more /etc/passwd
    siemens:x:107:1::/var/siemens:/sbin/nologin
    alcatel:x:108:1::/var/alcatel:/sbin/nologin
    ericsson:x:109:1::/var/ericsson:/sbin/nologin

本帖参考:
      http://hi.baidu.com/shineline/blog/item/ed12f0ec7ffba63c269791c5.html

阅读全文...