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

2024/03/05

linux在開几時要mount iscsi時
/etc/fstab使用 defaults 會無法開几


UUID=c46a08a2-160a-4345-9e96-8ebc35ff2220 /home                       xfs     defaults,uquota        0 0

要改成 _netdev 在網路啟動後再mount 就沒問題了

UUID=c46a08a2-160a-4345-9e96-8ebc35ff2220 /home                       xfs     _netdev,uquota



2019/02/25

上週借了一台 NeoSapphire P710 來測試

因為想測試在 proxmox 開大量guest後
每台guest上的iops情況
然後分成 iscsi 和 nfs

在create 和  destroy 大量的guest後
再次create要啟動時出現

ioctl(KVM_CREATE_VM) failed: 12 Cannot allocate memory
kvm: failed to initialize KVM: Cannot allocate memory

查了一下應該是ram 的問題

用以下指令處理完後就ok了

sync ; echo 1 > /proc/sys/vm/drop_caches

2017/02/21

前一陣子升級proxmox後發生一個問題
原來使用的hp storage連不上了
找了半天才發現因為proxmox新server的
initiatorname 不同了
在hp cmc上修改後連線就正常了
但連上後發現另一個問題就是裡面還殘留升級前的檔案
因為升級後已經先搬到server的肚子
所以這些檔案就變成占空間的垃圾
而且也無法從管理介面上刪除
要用指令刪除

先用 lvdisplay 找出有那些不用的image

再使用 lvremove 刪除
lvremove /dev/test/vm-121-disk-1

https://forum.proxmox.com/threads/remove-disk-images-from-lvm.10215/

2014/09/01

proxmox 在 hp virtual store left hand 11.0的版本下無法正常使用
更新到 11.5後目前看來是正常

隨後進行測試
二台proxmox 一開始各跑十隻guest進行i/o test
由下圖中可以看出各約1G 的流量
但在第一台再加5隻guest而第二台不變的情況下
可以看出第一台的流量增加
但第二台減少
由此可以看出storage可以提供的總流量是固定的
如下第三個圖所示











2014/08/14

hp的virtual store竟然無法在多台proxmox的情況下作業
會造成host os的down g
目前已詢問原廠是否有解決方案
考慮最差的情況應該就是拿一台机器把iscsi捉進來
再用nfs share出來了
因為容量超過2T所以必須使用之前的方法來處理
另外mount -t xfs /dev/sdb1 /mnt這個動作如果寫在/etc/rc.local
會因為執行太早網路還沒起來而無法成功
因此使用另一個方法
把開机後執行的指令放到crontab 裡

@reboot /root/0814test

0814test的內容如下

#!/bin/bash
/usr/bin/sleep 10
/usr/bin/mount -t xfs /dev/sdb1 /mnt

目前測起來工作是正常
只是nfs如果斷線重連
guest os還是有可能有問題需要重開
跟之前的預期有落差

2012/06/23

之前用openfiler來測iscsi給proxmox用
測完把openfiler拿掉後
proxmox的機器上就一直出現


/dev/sdh: read failed after 0 of 4096 at 0: Input/output error
/dev/sdh: read failed after 0 of 4096 at 10234036224: Input/output error
/dev/sdh: read failed after 0 of 4096 at 10234093568: Input/output error
/dev/sdh: read failed after 0 of 4096 at 4096: Input/output error

這樣的error
應該是雖然iscsi拿掉
但os捉到的disk卻還掛著
本來是想不理他
等下次升級kernel再reboot應該就會解決了
但最近的排程backup一直出問題
不知道是不是因為這個原因
所以查了一下資料
要怎麼在不reboot的情況下把disk拿掉
只要一行指令

echo offline > /sys/block/sdh/device/state

雖然在/proc/scsi/scsi還是有看到


Host: scsi9 Channel: 00 Id: 00 Lun: 00
  Vendor: OPNFILER Model: VIRTUAL-DISK     Rev: 0
  Type:   Direct-Access                    ANSI  SCSI revision: 04
Host: scsi10 Channel: 00 Id: 00 Lun: 00
  Vendor: OPNFILER Model: VIRTUAL-DISK     Rev: 0
  Type:   Direct-Access


但i/o error的訊息不會再跑出來了



2012/05/25


今天使用了openfiler測了一下iscsi
感覺還不錯用
iscsi應該是未來考慮的方向
但iscsi無法用來backup
所以backup還是要用nfs

LVM Groups with Network Backing

In this configuration, network block devices (iSCSI targets) are used as the physical volumes for LVM logical volume storage. This is a two step procedure and can be fully configured via the web interface.
  1. First, add the iSCSI target. (On some iSCSI targets you need to add the IQN of the Proxmox VE server to allow access.)
    • Click 'Add iSCSI Target' on the Storage list
    • As storage name use whatever you want but take care, this name cannot be changed later.
    • Give the 'Portal' IP address or servername and scan for unused targets
    • disable 'use LUNs direcly'
    • Click save
  1. Second, add LVM group on this target.
    • Click 'Add LVM Group' on the Storage list
    • As storage name use whatever you want but take care, this name cannot be changed later.
    • For 'Base Storage', use the drop down menu to select the previously defined iSCSI target.
    • For 'Base Volume' select a LUN
    • For 'Volume Group Name' give a unique name (this name cannot be changed later).
    • Enable shared use (recommended)
    • Click save


http://pve.proxmox.com/wiki/Storage_Model#LVM_Groups_with_Network_Backing