# File system full



## drunkenmidget (Oct 14, 2011)

Hello,

I've installed 3 jails with ezjail under /jails.  I didn't think this through too thourougly because the / directory only has 900 MB of disk space.  As a consequence, my jails only have 900 MB of disk space.  How can I move my jails to /usr/jails without breaking anything.  I've done quite a lot of configuration inside the jails, and I don't want to have to delete, then recreate them under /usr/jails.  Is there a way to move my jails from /jails to /usr/jails without breaking anything?  I have 65 GB of disk space under /usr.  That's more than enough for my needs.  If anyone can help me, I'd be appreciative.


----------



## drunkenmidget (Oct 14, 2011)

I solved my own problem, and for posterity I'll write the steps involved.


`# /usr/local/etc/rc.d/ezjail.sh stop httpd`
removed the symlink /usr/jails/httpd going to /jails/httpd
`# mv /jails/httpd /usr/jails`
I changed /etc/fstab.hostname from 

```
/usr/jails/basejail /jails/httpd/basejail nullfs ro 0 0
```
   to

```
/usr/jails/basejail /usr/jails/httpd/basejail nullfs ro 0 0
```

I changed /usr/local/etc/ezjail/httpd from 

```
export jail_httpd_rootdir="/jails/httpd"
```
   to

```
export jail_httpd_rootdir="/usr/jails/httpd"
```


That solved my problem.  For posterity, I wrote up the solution to my problem.  I'm sure, at some point, someone will want to know how to move a jail and not know how to do it.


----------



## SirDice (Oct 14, 2011)

drunkenmidget said:
			
		

> Is there a way to move my jails from /jails to /usr/jails without breaking anything?


Something like this should do it:

```
tar -C / -cf - jails | tar -C /usr -xvf -
```


----------

