# poudriere jail error "lstat of newly made dir failed: File name too long"



## avner (Sep 2, 2022)

Need some help trying to set up poudriere for single host server. Only installed a few packages so far for instance: git, ccache.

Was able to create poudriere jail using "poudriere jail -c ..."

Was able to download ports tree using "poudriere ports -c"

environment:
13.1-RELEASE on dell r710, 72G ram, UFS file system

```
root@daria:/usr/local/etc # ccache --set-config=cache_dir=/ja0/poudriere/.ccache

root@daria:/usr/local/etc # poudriere jail -l
13-1-amd64 13.1-RELEASE-p2 amd64 http   2022-09-01 00:01:31 /ja0/poudriere

root@daria:/usr/local/etc # poudriere ports -l
default   git+https 2022-09-01 23:48:48 /ja0/poudriere/ports/default

root@daria:/usr/local/etc # poudriere jail -s -j 13-1-amd64
[00:00:00] Creating the reference jail...data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data: mkdir failed: File name too long
data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/data: lstat of newly made dir failed: File name too long
```


----------



## Alain De Vos (Sep 2, 2022)

Could it be a circular symbolic link , ie indefinite?


----------



## Lamia (Sep 2, 2022)

Poudriere can be fussy with jail names. Try avoid special characters e.g. -,_, etc.


----------



## avner (Sep 2, 2022)

Lamia said:


> Poudriere can be fussy with jail names. Try avoid special characters e.g. -,_, etc.


I killed/destroyed the jail and then created a new one without "-" in the name but same problem. 

I did see poudriere.conf under a comment about not using "-" in package names. Not sure if this also somehow applies to jail names. I thought I remember reading somewhere that "." is the only character not allowed in a jail name.


----------



## avner (Sep 2, 2022)

Alain De Vos said:


> Could it be a circular symbolic link , ie indefinite?


I agree that there is some type of circular loop going on but I can't identify the source.


----------



## avner (Sep 2, 2022)

Now I can't even manage as root to delete the poudriere data files! Not allowed to change permissions. How is this possible?

root@daria:/ja0/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/lib # ll
total 2132
-r--r--r--  1 root  wheel  1955744 May 12 04:18 libc.so.7
-r--r--r--  1 root  wheel    52440 May 12 04:21 libcrypt.so.5
-r--r--r--  1 root  wheel   128224 May 12 04:20 libthr.so.3
root@daria:/ja0/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/lib # chmod 777 l*
chmod: libc.so.7: Operation not permitted
chmod: libcrypt.so.5: Operation not permitted
chmod: libthr.so.3: Operation not permitted
root@daria:/ja0/data/.m/13-1-amd64-default/ref/data/.m/13-1-amd64-default/ref/lib #


----------



## avner (Sep 2, 2022)

took the nuclear solution and overwrote the filesystem. I think I am more of a pkg type of guy.


----------

