0

I've created a jail to host my webserver/blog, but when attempting to build any port, I consistently get the message "portsnap: Directory is not writable: /usr/ports".

Attached is a screen capture of my console outputs attempting to portsnap fetch/extract/update console screen cap

I'm not certain how to deal with this. installing from pkg works, but I want ports so that I can build my own binaries (also, to understand what the heck is going on and how to resolve it).

  • The easy answer is "Don't build ports in a Jail". Build the package on the base system, or using Poudriere. Then install the packages you built in the jail. – Chris S Nov 1 '14 at 15:06
  • Interesting. How would you go about that? Wouldn't that also be possible by mounting ports inside the jail, permitting access to the build? – SteveMustafa Nov 1 '14 at 15:13
  • In the port's directory make package and the package will be dumped in /usr/ports/packages/. Setting up and using Poudriere isn't very hard either, and makes rebuilding packages for updates easier. – Chris S Nov 1 '14 at 16:08
0

The best idea - don't build packages in jail.

You could use pkg , or pkgng

But, if you want, create this dir

mkdir /usr/ports

And if its needed you could change permissions

chmod ... /usr/ports
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.