# CAM status: SCSI Status Error



## balanga (Dec 20, 2016)

I have a VPS running FreeBSD 10.1-RELEASE-p41 on amd64

and see numerous instances of the following errors when running `dmesg`


```
(da0:mpt0:0:0:0): CAM status: SCSI Status Error
(da0:mpt0:0:0:0): SCSI status: Busy
(da0:mpt0:0:0:0): Retrying command
(da0:mpt0:0:0:0): WRITE(10). CDB: 2a 00 01 fc b9 22 00 00 40 00
```

Can anyone tell me what is happening?


----------



## SirDice (Dec 20, 2016)

I'm doubtful this is a VPS, they generally don't emulate an LSI Fusion Fibre Channel card. Which VPS provider is this? Or do you have some technical details of their infrastructure (what virtualization technology is used)?


----------



## balanga (Dec 20, 2016)

https://www.exone.pl/en/servers/vps/calculator

I believe they use VMWare...

I use vCentre - vSphere Client to gain console access.


----------



## balanga (Dec 22, 2016)

balanga said:


> I have a VPS running FreeBSD 10.1-RELEASE-p41 on amd64
> 
> and see numerous instances of the following errors when running `dmesg`
> 
> ...



Any takers?


----------



## SirDice (Dec 22, 2016)

Make sure VMWare is up to date. And I'd also update the machine to 10.3. FreeBSD 10.1 will be end of life at the end of this year.


----------



## gkontos (Dec 23, 2016)

balanga said:


> https://www.exone.pl/en/servers/vps/calculator
> 
> I believe they use VMWare...
> 
> I use vCentre - vSphere Client to gain console access.


Can you see which vmware version they use? I have the same problems with a VM running in an old vmware server.


----------



## balanga (Dec 23, 2016)

Not sure how to tell....

vCenter - vSphere Client --->Help-->About VMWare vSphere  shows VMWare vCenter Server Version 6.0.0

Hope this helps


----------



## balanga (Dec 23, 2016)

SirDice said:


> Make sure VMWare is up to date. And I'd also update the machine to 10.3. FreeBSD 10.1 will be end of life at the end of this year.



I'm a bit nervous about doing something like this on a remote VPS. Can you provide a link which explains how to do this?

I guess I should ask the provider to update their FreeBSD offering.


----------



## SirDice (Dec 23, 2016)

balanga said:


> Can you provide a link which explains how to do this?



https://www.freebsd.org/releases/10.3R/relnotes.html#upgrade

It basically boils down to this:
`freebsd-update upgrade -r 10.3-RELEASE` # This is going to take a while
`freebsd-update install`
`shutdown -r now`
`freebsd-update install` # May need to be repeated


----------



## gkontos (Dec 23, 2016)

balanga said:


> Not sure how to tell....
> 
> vCenter - vSphere Client --->Help-->About VMWare vSphere  shows VMWare vCenter Server Version 6.0.0
> 
> Hope this helps


Yes, I think it is the same version with the one I am having the same issues. I also get a lot of : em0: Watchdog timeout -- resetting

I believe that it is quite safe for you to upgrade. I am running 10.3-RELEASE. If you have the option to take a snapshot before it would be good to use it though.


----------



## balanga (Dec 23, 2016)

gkontos said:


> Yes, I think it is the same version with the one I am having the same issues. I also get a lot of : em0: Watchdog timeout -- resetting
> 
> I believe that it is quite safe for you to upgrade. I am running 10.3-RELEASE. If you have the option to take a snapshot before it would be good to use it though.




I believe I saw the: em0: Watchdog timeout -- resetting message recently before doing a reboot last week.

As for taking a snapshot, how would I go about doing one?


----------



## gkontos (Dec 24, 2016)

I am not sure how. Have you searched for that option in vSphere Client ? 
When I perform maintenance on that VM, I usually call the DC and they do it for me.


----------



## timbo (Jun 2, 2017)

I have had the error 

"(da0:mpt0:0:0:0): CAM status: SCSI Status Error
(da0:mpt0:0:0:0): SCSI status: Busy
(da0:mpt0:0:0:0): Retrying command
(da0:mpt0:0:0:0): WRITE(10). CDB: 2a 00 01 fc b9 22 00 00 40 00"

in my FreeBSD daily logs.   The issue was on a HP DL380 G7 with vmware esxi, the cause turned out to be the cache controller battery which had failed resulting in disk read times upto 15 seconds.   As soon as I replaced the cache controller battery the disk performance returned to normal and the error messages stopped.  If the cache controller battery has a solid amber light on the 3rd led suggesting it is faulty.  This Steady glow means— There is a short circuit across the battery terminals or within the battery
pack. BBWC features are disabled until the battery pack is replaced.   

The only way I could check the battery was to take the cover off the G7 and inspect the LEDS.  There was no sign of a problem in iLo


I hope this helps someone else save a bucket load of time.


----------



## ralphbsz (Jun 2, 2017)

That means that VMware is providing a crappy (or great?) SCSI emulation: They turn a successful but slow SCSI operation (it's perfectly valid for a SCSI Read(10) or Write(10) command to take 15 seconds) into an error.  That's either idiocy or genius, depending how you look at it.  Personally, I haven't found a SCSI emulation yet that I didn't hate, because they always do such a crappy job of pretending to be SCSI.  It seems that the only really good SCSI implementations are real native SCSI devices (Seagate, Hitachi and the like).  In particular, Linux is chock full of SCSI emulations (for things like SATA and NVMe) that look like they were written by drunk undergraduates.


----------

