顯示具有 CentOS 標籤的文章。 顯示所有文章
顯示具有 CentOS 標籤的文章。 顯示所有文章

2013年5月17日 星期五

[VMware] CentOS 3 P2V faild "again" ...

今天在TM學園 P2V 了一台CentOS 3.9 ( 沒錯,真的是3.9... ),過程一波多折,紀錄一下狀況.[[MORE]]

一開始出現 error loading operating system ,這個簡單,GRUB 重新安裝即可,步驟如下:

  1. Boot on CentOS DVD.

  2. 按下 F5 -> 輸入linux rescue ,進入rescue模式.

  3. 輸入以下指令重建GRUB:
    chroot /mnt/sysimage
    grub
    root (hd0,0)
    setup (hd0)
    quit



這樣就重建完成了,原本以為大功告成,誰知道... SCSI Controller 又出問題,可能是因為原本是 IDE 轉VMware 的LSI Logic SCSI卡,解決方法如下:

  1. Boot on CentOS DVD.

  2. 按下 F5 -> 輸入linux rescue ,進入rescue模式.

  3. 修改前先備份是一定要的好習慣. ( RHEL4、5請將 modules.conf 改成 modprobe.conf )
    cp /etc/modules.conf /tmp


  4. 修改 modules.conf.
    vi  /etc/modules.conf
    ##刪除掉原本的 SCSI Controller ,再加入
    alias scsi_hostadapter mptbase
    alias scsi_hostadapter1 mptscsih


  5. 重新編譯 initrd,編譯前先確定version
    uname -a
    ##注意一下,下面這個 initrd 檔,應該和GRUB的開機選單裡的設定一致
    /sbin/mkinitrd -f /boot/initrd-2.4.21-50.ELsmp.img 2.4.21-50.ELsmp


  6. 重新開機,大功告成.


解決問題方法可能千百種,只能不斷 Try,才可以得永生!

參考資源:

How to Change SCSI Controllers on your Linux VM

2013年5月16日 星期四

[UPS] 飛瑞 UPS Winpower for Linux 安裝注意事項


  1. 有加裝 USHA 卡的朋友,請直接跳過.[[MORE]]

  2. RS-232 cable 記得接上. (廢話)

  3. 沒有圖形介面的 Host ,安裝的時候選擇 setup_console.bin,有圖形介面選擇 setup.bin

  4. iptables 要放行 udp 的 Port 2198、2199、2200.

  5. 基本上只要 iptables 有設定好,有圖形介面的 Host 就可以去 monitor 沒有圖形介面的 Host.


一開始飛X的人員還叫我乾脆不要開 iptables ,這樣對嗎?...

相關資源:

各版本 Winpower 下載頁面

2013年5月15日 星期三

[CentOS] CentOS 指令之路...

今天在CL學園,對上CentOS 5.9真是碰了不少釘子,果然每個Linux的指令及概念都不大一樣,記下來以後方便些...[[MORE]]

  1. 重新啟動網路卡:
    #/etc/rc.d/init.d/network restart //方式一
    #service network restart //方式二

  2. 修改網路設定:
    # vi /etc/sysconfig/network-scripts/ifcfg-eth0  //範例如下
    # BOOTPROTO = STATIC
    # IPADDR = xx.xx.xx.xx
    # NETMASK = 255.255.255.xxx
    # GATEWAY = xx.xx.xx.xx
    # ONBOOT = yes

  3. 設定DNS Server 位址
    # vi /etc/resolv.conf  //範例如下
    # nameserver 168.95.1.1
    # nameserver 8.8.8.8

  4. 將root以外的帳號加入一般sudo:
    # su
    # chmod u+w /etc/sudoers
    # vi /etc/sudoers
    找到 root ALL=(ALL) ALL 在下面添加 xxx ALL=(ALL) ALL (xxx = username)

    # chmod u-w /etc/sudoers

[Storage] IBM DS3512 安裝注意事項




CL學園數位組新買了Storage 和 Server,要做 DB server,下面是安裝環境:

storage:IBM DS3512,雙controller,fibre port共8 ports.[[MORE]]

server:IBM x3650 m4,加裝2片HBA卡,系統使用CentOS 5.9 server + Desktop GNOME

 

注意事項:

  1. default ip:192.168.128.101、192.168.128.102、192.168.129.101、192.168.129.102.

  2. 如果忘記IP,可以架臨時DHCP Server讓Controller去取得IP即可.

  3. frimware和disk manager的版本需對應.

  4. 每個Linux DS Manager 版本的安裝方式不一,必須自行參照原文"Readme".(IBM原廠回覆...)

  5. 建立RAID -> 建立Logic Drive,設定LUN-> 設定Host Group -> 設定Host,指定WWPN -> 將LUN Mapping到Host/Host Group

  6. 要多個Host使用同一個LUN,Mapping的時候,選擇Host Group.

  7. 下載新版本DS Manager 的時候,會發現有 SMIA 和 single 兩種版本可供安裝,後來查了一下IBM RedBook,SMIA的意思就是 Storage Manager in Anywhere.


相關資源:

  1. DS 3500 Series spec

  2. DS 3500 Support Download


 

 結論:甚麼東西只要放到Linux之下,都是一個折騰...

2012年2月4日 星期六

[VMware] CentOS or Fedora P2V failed

今天轉了12台實體機,除了3台2K3、2台B2D之外,都是Fedora或CentOS,其中幾台轉完後無法正常啟動系統,錯誤訊息如下:

[[MORE]]
* Mounting /dev/VolGroup00/LogVol00 on /sysroot
mount: mounting /dev/VolGroup00/LogVol00 on /sysroot failed: No such file or directory
mount: mounting /dev on /sysroot/dev failed: No such file or directory
* Switching / to /sysroot
switch_root: bad newroot /sysroot
Kernel panic - not syncing: Attempted to kill init!


解決方法1:

這是最簡單的方法,使用vCenter Converter Standalone 5作P2V的時候,去編輯data to copy的地方,選Advanced view ->  Destination,選取包含 / 的虛擬磁碟,再點選 To Basic 的 "按鈕" ,之後其他步驟照舊即可.

解決方法2:

挺麻煩的,請參閱 VMKB: 325984