PDA

View Full Version : Hubbles Ports Console


bsdaddict
02-28-2010, 02:21 PM
If I understand it correctly, the previous method of installing ports via console (with first "runports" and then the "make && make install clean" is no longer needed.
But i'm trying to install either mail/bogofilter or mail/p5-Mail_SpamAssassin as a spamfilter.
Launching the PortsConsole gives me a console, but there is no way to cd into /usr/ports/mail/. I have tried then to "pkg_add -r bogofilter" (or spamassassin) but that gives me a whole load of errors, most of them "failed to create dir" related.
How do i install a port (or package) in Hubble ? The portstree and source were installed during the clean install of pcbsd8.
Thanks,
Beni.

Fatmice
03-01-2010, 02:40 AM
I advice you to search the forum before asking, it might save you oodles of time.

Any how, please refer to this thread (http://forums.pcbsd.org/viewtopic.php?p=84882#p84882). I've suggested a way to fix it. :)

Good luck!

bsdaddict
03-01-2010, 07:02 AM
I did search the formum before asking and i did find your thread.
But as you say it yourself, it "is call an improper hack...or desperation", so i am not that tempted to do those kind of things :)
Beni.

Fatmice
03-02-2010, 11:55 AM
I was referring to the poster's hacks, not mine.... :(

bsdaddict
03-02-2010, 06:10 PM
After applying your changes (adding those 2 lines of code) to /usr/PCBSD/portjail/portjail.sh, saving the file and launching it, i get this :

root@bsdaddict# /usr/PCBSD/portjail/portjail.sh start
ifconfig: create: bad value
mount_nullfs: Resource deadlock avoided
mount_nullfs: Resource deadlock avoided
mount_nullfs: Resource deadlock avoided
mount_nullfs: /usr/jails/portjail/usr/ports: No such file or directory
jail: jail "portjail" already exists
root@bsdaddict#

Somehow i don't think that this is what it's supposed to look like...
Beni.

Fatmice
03-03-2010, 03:00 AM
The jail starts automatically when you start the machine. You need to shut it down then restart it.

Does it give the same error? You sure you type everything as it should? I created the patch based on Revision 5750.

bsdaddict
03-03-2010, 01:03 PM
Clicking the icon Ports Console on the Desktop, opens up a console. An ls of /usr gives me this :
[beni@bsdaddict]/(38)% ls /usr/
bin games home include lib libdata libexec local obj sbin share src
[beni@bsdaddict]/(39)%

So still no /usr/ports. Launching /usr/PCBSD/portjail/portjail.sh start from a normal console gives me this error :
root@bsdaddict# /usr/PCBSD/portjail/portjail.sh start
ifconfig: create: bad value
mount_nullfs: Resource deadlock avoided
mount_nullfs: Resource deadlock avoided
mount_nullfs: Resource deadlock avoided
mount_nullfs: /usr/jails/portjail/usr/ports: No such file or directory
jail: jail "portjail" already exists
root@bsdaddict#

I copied and pasted your code into portjail.sh, so yes it should be the correct code. I only used your code (adding the mount and umount) and not the code from foo_daemon.
Beni.

Fatmice
03-03-2010, 02:32 PM
jail: jail "portjail" already exists
root@bsdaddict#


The jail already exist! You need to stop it first.

bsdaddict
03-03-2010, 02:39 PM
Still no /usr/ports in the portjail :

root@bsdaddict# locate portjail.sh
/usr/PCBSD/portjail/portjail.sh
root@bsdaddict# /usr/PCBSD/portjail/portjail.sh stop
Stopping cron.
Terminated
.
umount: /usr/jails/portjail/usr/ports: statfs: No such file or directory
umount: /usr/jails/portjail/usr/ports: unknown file system
root@bsdaddict# /usr/PCBSD/portjail/portjail.sh start
mount_nullfs: /usr/jails/portjail/usr/ports: No such file or directory
Setting hostname: bsdaddict.
Creating and/or trimming log files.
ln: /dev/log: Operation not permitted
Starting syslogd.
ELF ldconfig path: /lib /usr/lib /usr/lib/compat
a.out ldconfig path: /usr/lib/aout /usr/lib/compat/aout
Updating motd:.
Starting cron.

Wed Mar 3 15:36:40 UTC 2010
root@bsdaddict# portjail console
bsdaddict# pwd
/
bsdaddict# cd /usr/
bsdaddict# ls
bin games home include lib libdata libexec local obj sbin share src
bsdaddict# cd ports
ports: No such file or directory.
bsdaddict#

Fatmice
03-03-2010, 02:56 PM
Duh!, I forgot.

mdkir /usr/jails/portjail/usr/ports

This folder must exist for there to be a mount point.

Kill the jail, then make the folder, then restart the jail.

bsdaddict
03-03-2010, 03:08 PM
hip hip hooray ! /usr/ports is there now. I will try to install some ports now...
Thanks very much for your help here :)
Beni.

PS : i suppose i am not the only one having had this problem with portjail ? Do i report this problem or are de developers already working on an official patch ?

Fatmice
03-03-2010, 03:58 PM
hip hip hooray ! /usr/ports is there now. I will try to install some ports now...
Thanks very much for your help here :)
Beni.

PS : i suppose i am not the only one having had this problem with portjail ? Do i report this problem or are de developers already working on an official patch ?


Your guess is as good as mine. I do not track the bug list server so I do not know...Maybe I should track this list serve.

mechanic
03-10-2010, 11:37 AM
PS : i suppose i am not the only one having had this problem with portjail ? Do i report this problem or are de developers already working on an official patch ?
Why bother? Just use the ports installed to /usr/ports and compile there (probably that's how FreeBSD does it). This jail stuff just sets up an alternate file system which takes up lots of Gigas, and doesn't seem aware of the running OS libraries.

And relying on forum posts for documenting this feature just sucks!

bsdaddict
03-10-2010, 11:54 AM
I know how freebsd ports are installed. But this was a pc-bsd "problem"...
So i do bother to get it fixed somehow.
Since this is the pc-bsd forum, i asked the question here. Do you have other suggestions on how to get it documented besides the posts here ? More people read and answer here than on the Freenode chat-channel.

Fatmice
03-11-2010, 07:04 AM
Well...maybe I'll talk to chris and get the word on how port jail was suppose to work...

bjs
03-11-2010, 06:35 PM
That would be great if you could and post a how-to since I would likely be building a few ports sooner or later and would like to get it right the first time and not have to spend days trying to repair some mistake or worst, reinstall everything from scratch.

Fatmice
03-11-2010, 11:55 PM
I'll get a 8.0 box running next week and see what's going on.

psi
03-16-2010, 08:28 PM
I'll get a 8.0 box running next week and see what's going on.

Thx for this info! I had to add these as well :

mount_nullfs /usr/local ${PJDIR}/usr/local
umount ${PJDIR}/usr/local

I was building wine and it requires flex to build but couldn't find the installed flex. It wanted to download and build flex instead.

Edit:

Right, I don't think I like this portsjail thing. While in the jail, there's no internet access. For now I'm using the standard way of building ports. What exactly was/is the purpose of the jail and how does not using it affect my system?

rekeaki
03-20-2010, 10:26 AM
I'm not sure if I'm just stating the obvious or if I am simply mentioning something that everyone tried first before they had all these problems, But I made the ports tree show up in the portjail by going to the system settings then system manager and The "tasks" tab lets you Fetch the ports tree in the jail. Once I did this it was all good.

my only problem after that was getting my installed software out of the jail (or finding a way to link to them from my menu).

My only other post on this forum is on that topic. If anyone can help I would appreciate it.

mechanic
06-23-2010, 11:03 AM
Is this sorted now in version 8.1 - anyone?

kmoore134
06-23-2010, 12:37 PM
The gui section described is one way to fetch ports into the ports jail.
Another option is to use "portsnap fetch extract update" inside the
jail, which is what the gui does as well.

As for running commands inside the jail, here's some information on
doing so:

http://wiki.pcbsd.org/index.php/PC-BSD_Users_Handbook#Using_the_Ports_Console.2FJail ('http://wiki.pcbsd.org/index.php/PC-BSD_Users_Handbook#Using_the_Ports_Console.2FJail' )

So you would use "portjail run <cmd>", and you can setup KDE desktop
icons using that as well.