# LUN size



## kendotone (Oct 10, 2011)

Not really sure if this fits in Networking or not. But my question is, what is the MAX size LUN that FreeBSD does not have a problem with? From my understanding, Windows has a LUN limitation of 2TB. I currently have 2TB Luns mounted to FreeBSD with no problem.

I am having a problem mounting 5.36TB LUNS. FreeBSD sees the devices but I cannot *newfs* the drive. I have a RAID on the server that is 5TB and it *newfs*'d fine and mounts fine.


----------



## SirDice (Oct 10, 2011)

Maximum UFS2 volume size is 1YB.


----------



## kendotone (Oct 10, 2011)

*How?*

How do I format the partition to use UFS2? I am reading about GPT, but am getting confused because it is saying I need to boot off of a GPT formated disk? I dont want to change anything bo-wise, I just want to be able to mount the 5TB Lun.


----------



## SirDice (Oct 10, 2011)

kendotone said:
			
		

> How do I format the partition to use UFS2?


newfs(8)


----------



## wblock@ (Oct 10, 2011)

kendotone said:
			
		

> How do I format the partition to use UFS2?
> 
> I am reading about GPT, but am getting confused because it is saying I need to boot off of a GPT formated disk?



What is saying that?


----------



## kendotone (Oct 10, 2011)

```
newfs -O 2 (for UFS2) /dev/da4
```
 does not work

Says 'could not open special device' which is the problem I have been having.


----------



## SirDice (Oct 10, 2011)

Perhaps you should try partitioning it first.


----------



## kendotone (Oct 10, 2011)

`fdisk /dev/da4` outputs this error


```
fdisk: unable to get correct path for /dev/da4: invalid argument
```


----------



## kendotone (Oct 10, 2011)

Should I be using gpart?


----------



## wblock@ (Oct 10, 2011)

What makes you think it is da4?


----------



## kendotone (Oct 10, 2011)

That is where camcontrol says it is:

```
<HITACHI OPEN-V 5009>              at scbus0 target 0 lun 0 (da0,pass0)
<HITACHI OPEN-V 5009>              at scbus0 target 0 lun 1 (da1,pass1)
<HITACHI OPEN-V 5009>              at scbus0 target 0 lun 2 (da2,pass2)
<HITACHI OPEN-V 5009>              at scbus0 target 0 lun 3 (da3,pass3)
<HITACHI OPEN-V*3 5009>            at scbus0 target 0 lun 4 (da4,pass4)
<HITACHI OPEN-V*3 5009>            at scbus0 target 0 lun 5 (da5,pass5)
<HITACHI OPEN-V*3 5009>            at scbus0 target 0 lun 6 (da6,pass6)
<HITACHI OPEN-V*3 5009>            at scbus0 target 0 lun 7 (da7,pass7)
<HITACHI OPEN-V*3 5009>            at scbus0 target 0 lun 8 (da8,pass8)
<HITACHI OPEN-V*3 5009>            at scbus0 target 0 lun 9 (da9,pass9)
<HITACHI OPEN-V*3 5009>            at scbus0 target 0 lun 10 (da10,pass10)
<HITACHI OPEN-V*3 5009>            at scbus0 target 0 lun 11 (da11,pass11)
<HITACHI OPEN-V*3 5009>            at scbus0 target 0 lun 12 (da12,pass12)
<HITACHI OPEN-V*3 5009>            at scbus0 target 0 lun 13 (da13,pass13)
<HITACHI OPEN-V*3 5009>            at scbus0 target 0 lun 14 (da14,pass14)
<HITACHI OPEN-V*3 5009>            at scbus0 target 0 lun 15 (da15,pass15)
<HITACHI OPEN-V 5009>              at scbus0 target 0 lun 256 (da16,pass16)
```

LUNS - 0 through 3 are 2TB in size. Luns 4-15 are 5TB in size.
LUNS - 0 through 3 are working fine with nothing done to them besides *newfs /dev/da0-3* and then setting up a mount point for them

LUNS - 4 through 15 are not allowing me to newfs, bsdlabel, fdisk. 

SAN seems to be setup and working properly. HBA cards are working properly. No issues with OS.


----------



## DutchDaemon (Oct 11, 2011)

kendotone, start formatting your posts now, thanks.


----------



## ecazamir (Oct 13, 2011)

It may be useful to enable debugging at SCSI layer. Set these parameters on a kernel configuration file and rebuild the kernel

```
CAM_DEBUG_BUS=-1
CAM_DEBUG_TARGET=-1
CAM_DEBUG_LUN=4
```
See man 4 CAM for more details on SCSI debugging.
PS: VMWare ESX 3.5 does not support LUNs larger than 2 TB with some QLogic controllers, so I wouldn't be surprised if FreeBSD does the same, at least with a specific controller.
What controller do you use to connect to the storage volumes?


----------



## geodni (Oct 13, 2011)

Hi,

According to Hitachi documentation top of page 3-8, OPEN-V LU types may vary from 48.1MB to 4TB. You have configured 5TB each.

Maybe your model does not correspond or I made a mistake reading this doc so my suggestion could not apply.


----------



## ecazamir (Oct 14, 2011)

Firmware updates can enable larger volumes. I've seen that on IBM DS.


----------

