# questions about freebsd 8



## wonslung (Jun 25, 2009)

I was wondering a couple things about 8.0

First, is the system stable enough to use right now if all you wanted was ZFS and maybe a small torrent program like rtorrent or something?  Also, i have 7.2-stable right now and if i wanted to TRY 8.0 would i be able to "import" my zfs file system without having to whipe it?  and if i did decide 8.0 wasn't for me could i downgrade to 7.2 again?  I do not have root or /usr on the ZFS filesystem, i'm basically just wondering if i could try it without loosing all my ZFS data.


ALSO, is there any sort of roadmap online somewhere that lists the scheduled release date?  IS there even a release date yet or is it still under pretty heavy development, i did see a site that showed the new features in 8 but it didn't really give any word on when it's due to drop.

thanks


----------



## mousaka (Jun 25, 2009)

wonslung said:
			
		

> First, is the system stable enough to use right now if all you wanted was ZFS and maybe a small torrent program like rtorrent or something?  Also, i have 7.2-stable right now and if i wanted to TRY 8.0 would i be able to "import" my zfs file system without having to whipe it?  and if i did decide 8.0 wasn't for me could i downgrade to 7.2 again?  I do not have root or /usr on the ZFS filesystem, i'm basically just wondering if i could try it without loosing all my ZFS data.


ZFS is version 13 in both CURRENT and 7-STABLE, so there should be no issue in using ZFS. Therefor I would use 7-STABLE right know.
Note: 7.2-RELEASE still has ZFS V6, so if you update your system you should update your ZFS pools as well. A downgrade of ZFS pools (V13 to V6) is not possible.



> ALSO, is there any sort of roadmap online somewhere that lists the scheduled release date?  IS there even a release date yet or is it still under pretty heavy development, i did see a site that showed the new features in 8 but it didn't really give any word on when it's due to drop.


Generally 8.0-RELEASE is planed for the end of August (http://www.freebsd.org/releng/), slightly more information can be found at
http://wiki.freebsd.org/8.0TODO.

7.3-RELEASE is planed for the end of 2009 as far as I know.

mousaka


----------



## wonslung (Jun 25, 2009)

in the past i've used linux distros that were 2 months from release without much issue, but being new to freebsd i'm really not sure how fast/slow things move in the freebsd world.

I know this is likely to be an apple to oranges question, but would trying to use freebsd 8.0 now be anything like trying to use an ubuntu version 2-3 months from release? or is it much more "broken"

actually, i'm just going to go ahead and download it and try it on a machine i don't really care that much about i guess...

thanks for the good links


----------



## SirDice (Jun 25, 2009)

With -CURRENT things can move pretty fast. That's what it's for. 

Having said that, I believe 8-CURRENT is pretty stable right now. Because the release date is closing in things don't change that much. It's mainly bug and stability fixes now.

Once 8.0-RELEASE is done the new 9.0-CURRENT will again move very fast. It usually best to stick to a -STABLE version if you want new features but also a stable system.


----------



## roddierod (Jun 25, 2009)

wonslung said:
			
		

> in the past i've used linux distros that were 2 months from release without much issue, but being new to freebsd i'm really not sure how fast/slow things move in the freebsd world.
> 
> I know this is likely to be an apple to oranges question, but would trying to use freebsd 8.0 now be anything like trying to use an ubuntu version 2-3 months from release? or is it much more "broken"



I had to use 7 Current for a year before it's release because it was the only version to boot on my machine. 

You're probably going to want to build a new kernel without the debugging features enabled because that will really speed the system up.

Such as these:

```
# Debugging for use in -current
options KDB # Enable kernel debugger support.
options DDB # Support DDB.
options GDB # Support remote GDB.
options INVARIANTS # Enable calls of extra sanity checking
options INVARIANT_SUPPORT # Extra sanity checks of internal
```

Also, you may not want to rebuild world so much once you get the system to a point were you feel it is stable. Because current is development things might be checked in that fix one problem but break something else. I had that problem with my SCSI adapter

Other than that you should be fine.


----------



## lme@ (Jun 25, 2009)

ATM 8-CURRENT is pretty stable and there's a Code Freeze coming soon, so things will settle down.
When you run CURRENT, you're strongly advised to read the current@ mailing list as this is the place, where the HEADSUP mails and the development takes place.


----------



## wonslung (Jun 25, 2009)

thanks for the info guys. I'm running 7.2-stable on 3 machines right now and i love it.  I will probably wait until 8 is offically released to put it on most of them but i think i will go ahead and try it on one of them just to see.

thanks again.


----------



## kungfujesus (Jun 25, 2009)

if stable didn't require so much compilation, I'd probably be using it on my ZFS right now.  Unfortunately the CF for root will probably not like my compiling (although I could put the source tree elsewhere).  It just seems like a hassle that I don't feel like doing.  The release copies tend to be upgradable with little problems.


----------



## SirDice (Jun 25, 2009)

kungfujesus said:
			
		

> if stable didn't require so much compilation, I'd probably be using it on my ZFS right now.


It only takes about 2-2.5 hours to build world and a kernel. And you could do it on another machine. Just do the build(world|kernel) there, NFS mount /usr/src and /usr/obj on your destination machine and start install(world|kernel).


----------



## DrJ (Jun 25, 2009)

SirDice said:
			
		

> It only takes about 2-2.5 hours to build world and a kernel.



You must have a *really* slow computer.  My seven-year-old box does this in about hour and a half; a modern 4-core system goes through the cycle in about 20 minutes.


----------



## vivek (Jun 25, 2009)

My box compile everything in 15 minutes. Dual core single cpu, 4GB RAM, RAID 1 sata. However, I've disable unwanted features such as ZFS, NIS, Bluethooth and so on using src.conf. I will try out 8 soon on one of those vmware boxes :e


----------



## kungfujesus (Jun 25, 2009)

I must agree NIS is very unwanted, and I don't know a soul who uses bluetooth (let alone on freebsd).  Most bluetooth keyboards and mice have USB HID adapters that will translate the bluetooth, anyway.


----------



## SirDice (Jun 25, 2009)

DrJ said:
			
		

> You must have a *really* slow computer.  My seven-year-old box does this in about hour and a half; a modern 4-core system goes through the cycle in about 20 minutes.



Even after a make clean and clearing out /usr/obj? 

I've got a core2 dual 1.8GHz, 1GB and plenty of space..


----------



## SirDice (Jun 25, 2009)

kungfujesus said:
			
		

> I must agree NIS is very unwanted, and I don't know a soul who uses bluetooth (let alone on freebsd).  Most bluetooth keyboards and mice have USB HID adapters that will translate the bluetooth, anyway.



I've been playing with it :e

Using rfcomm to get Internet connected via bluetooth on my 3G phone.


----------



## DrJ (Jun 25, 2009)

SirDice said:
			
		

> Even after a make clean and clearing out /usr/obj?


Yes.


> I've got a core2 dual 1.8GHz, 1GB and plenty of space..


Mine is a dual CPU Athlon (about a 3500+ by today's standards), 2GB, 15K SCSI.  Builds world in about 40 minutes with -j3.  A 3GHz Q6600 does it in 12 minutes with -j6.


----------



## vivek (Jun 25, 2009)

DrJ said:
			
		

> Yes.
> 
> Mine is a dual CPU Athlon (about a 3500+ by today's standards), 2GB, 15K SCSI.  Builds world in about 40 minutes with -j3.  A 3GHz Q6600 does it in 12 minutes with -j6.



Why not remove unwanted stuff; it will speed up things 

I never used -jX flag.


----------



## DrJ (Jun 25, 2009)

vivek said:
			
		

> I never used -jX flag.



That explains it.  I don't use it for the kernel (and probably could) but for world it works just fine.  That is the more time consuming of the two anyway.


----------



## phoenix (Jun 25, 2009)

kungfujesus said:
			
		

> if stable didn't require so much compilation, I'd probably be using it on my ZFS right now.  Unfortunately the CF for root will probably not like my compiling (although I could put the source tree elsewhere).  It just seems like a hassle that I don't feel like doing.  The release copies tend to be upgradable with little problems.



If you have a ZFS system, why aren't you using ZFS for /usr/src, /usr/obj, /usr/ports, and so forth?  There's really no reason to keep those on the CF disk.

In fact you can also move /usr/local, /home, /var, /tmp off the CF and onto ZFS as well.

That way, the only time the CF disk gets written to is when you manually edit something in /boot or /etc, or when doing an installkernel/installworld.


----------



## phoenix (Jun 25, 2009)

wonslung said:
			
		

> I was wondering a couple things about 8.0
> 
> First, is the system stable enough to use right now if all you wanted was ZFS and maybe a small torrent program like rtorrent or something?



-CURRENT is in "code slush" right now, leading up to a "code freeze", heading toward a release (tentatively) in August.  Things should be fairly stable and usable right now.



> Also, i have 7.2-stable right now and if i wanted to TRY 8.0 would i be able to "import" my zfs file system without having to whipe it?



Yes.  -CURRENT has ZFSv13, which can read/use pools from earlier versions.  If you are not using ZFSv13 on your -STABLE box, then do *not* upgrade your pools.  Once you upgrade your pools to ZFSv13, you cannot access them from earlier versions.



> and if i did decide 8.0 wasn't for me could i downgrade to 7.2 again?



Not easily.  You'd need to use separate partitions for -STABLE / and -CURRENT / (basically a dual-boot setup) in order to be able to revert back to -STABLE.


----------



## wonslung (Jun 25, 2009)

well i'm using zfs 13 right now with 7.2-stable...i have / and /usr set on compact flash cards and everything else except /etc on zfs (including /usr/local /usr/src /usr/obj and /var)

i'll likely wait to upgrade THAT machine till august if it's going to drop then.  


But if i DID upgrade it to 8.0 now and wanted to go back to 7.2-stable wouldn't it just be a matter of  installing 7.2-release, upgrading to 7.2-current then importing the pools?


I'm having some strange issues ever since i switched that machine to FreeBSD but i'm starting to think it's my ISP causing them and the fact that they coincide with the switch is just a coincidence.


The machine in question is a media server/torrent box.  I've always used torrentflux-b4rt, so i kept using it with FreeBSD.  Now whenever i download a torrent my internet latency goes way up.  (ping rates go from 30-70 ms up to 1000-2000 ms)  I've tried running different clients like rtorrent but it doesn't seem to matter.  Seeing as the only thing i changed was the os on this server it made sense that something with the OS was causing it MORE THAN LIKELY but I honestly can't find a problem with the setup. I finally decided to try hooking the cable modem directly to another computer and seeing if the same thing happened and it seems that it DOES....so it's got to be the cable....it's just REALLY been driving me nuts. I've had Comcast out here twice and they say it's working fine....and i guess it DOES until i try to download a torrent...it doesn't make sense that one torrent going at 190kB/sec down and maybe 20 KB up would cause that kind of lag does it? 


I can see Verizon putting FIOS lines down outside my neighborhood so soon it won't be an issue.  I'll be really happy to get out from under Comcast....Anyways....i'm getting way off topic.


----------



## phoenix (Jun 25, 2009)

wonslung said:
			
		

> But if i DID upgrade it to 8.0 now and wanted to go back to 7.2-stable wouldn't it just be a matter of  installing 7.2-release, upgrading to 7.2-current then importing the pools?



Yes, in theory that will work.  

You could also snapshot all your ZFS filesystems prior to the upgrade to 8-CURRENT.  Then, if need be, you can rebuild the OS as 7-STABLE, and do a "zfs rollback" to the snapshot taken prior to the upgrade.  That will revert the ZFS filesystems back to the state they were in before the upgrade.  In case you have /usr/bin, /usr/lib, or anything like that on ZFS (that would be modified by the installworld).



> The machine in question is a media server/torrent box.  I've always used torrentflux-b4rt, so i kept using it with FreeBSD.  Now whenever i download a torrent my internet latency goes way up.  (ping rates go from 30-70 ms up to 1000-2000 ms)  I've tried running different clients like rtorrent but it doesn't seem to matter.  Seeing as the only thing i changed was the os on this server it made sense that something with the OS was causing it MORE THAN LIKELY but I honestly can't find a problem with the setup. I finally decided to try hooking the cable modem directly to another computer and seeing if the same thing happened and it seems that it DOES....so it's got to be the cable....it's just REALLY been driving me nuts. I've had Comcast out here twice and they say it's working fine....and i guess it DOES until i try to download a torrent...it doesn't make sense that one torrent going at 190kB/sec down and maybe 20 KB up would cause that kind of lag does it?



Maybe Comcast has started throttling torrent traffic?

You can try configuring the torrent client to use a low port (like 70, the gopher port) to see if that improves things.  If it does, then they are definitely throttling individual ports.

Shaw Cable, my ISP, does something similar.  If you modify your MAC and get a new dynamic IP, you get a blazing fast connection for everything ... *UNTIL* you start a P2P app.  Then they throttle all ports over 1024, and some ports under 1024 (like SSH, bastards!!!).  We found that port 70 wasn't throttled, so we have to use that for our SSH traffic to work systems.


----------



## wonslung (Jun 26, 2009)

phoenix said:
			
		

> Yes, in theory that will work.
> 
> You could also snapshot all your ZFS filesystems prior to the upgrade to 8-CURRENT.  Then, if need be, you can rebuild the OS as 7-STABLE, and do a "zfs rollback" to the snapshot taken prior to the upgrade.  That will revert the ZFS filesystems back to the state they were in before the upgrade.  In case you have /usr/bin, /usr/lib, or anything like that on ZFS (that would be modified by the installworld).
> 
> ...



yah, it's also seems that the private sites don't cause the lag but as soon as i use a public sites the lag starts...the worst part about it is that it's not the top speed that suffers, it's the latency.  I can go to http://www.speedtest.net and run a test before i start a public torrent, get a low ping and about 15,000 Mbit/sec down 4,000 Mbit/s up then when i start a torrent the ping goes from like 30ms to like 1000 ms and the speed drops to about 9,000 or so

i could DEAL with the speed drop, it's the loss in latency that kills everything...and comcast SWEARS they don't throttle.  I'm really unhappy about it.

edit:

I just tried to set rtorrent to use a port under 1024 and i get this error

```
rtorrent: Could not open/bind port for listening: Permission denied
```


----------



## SirDice (Jun 26, 2009)

wonslung said:
			
		

> I just tried to set rtorrent to use a port under 1024 and i get this error
> 
> ```
> rtorrent: Could not open/bind port for listening: Permission denied
> ```


Only root can open ports <1024. Not a good idea to run rtorront as root.


----------



## wonslung (Jun 26, 2009)

yes, i agree.

Is there a way to grant the option to run on such ports to non root or is this best handled via redirect rules in pf?


----------



## richardpl (Jun 26, 2009)

Perhaps you are interested in *net.inet.ip.portrange.** sysctls?


----------



## SirDice (Jun 26, 2009)

IF you're on xDSL try to cut down your upload speed. Uploading close to the maximum of your connection seems to seriously impact download speeds.


----------



## DutchDaemon (Jun 26, 2009)

It certainly does. Either stick to about 80% of your upload speed, or use ALTQ to prioritise outgoing acks. This is often underestimated! A download of ~6 Mbit can easily cause ~300 Kbit of outgoing acks. If they're obstructed by other traffic or lack of bandwidth, your download will plummet, and you will cause extra traffic because of all the retransmits.


----------



## kungfujesus (Jun 26, 2009)

phoenix said:
			
		

> If you have a ZFS system, why aren't you using ZFS for /usr/src, /usr/obj, /usr/ports, and so forth?  There's really no reason to keep those on the CF disk.
> 
> In fact you can also move /usr/local, /home, /var, /tmp off the CF and onto ZFS as well.
> 
> That way, the only time the CF disk gets written to is when you manually edit something in /boot or /etc, or when doing an installkernel/installworld.



A very good reason: so that I can import and export the pools when they go into degraded state and my SATA controllers start flipping around drive order at random when I pop a new drive in.  I think that's a very good reason to keep the rootfs separate from the zpool.  Maybe if I had another CF I could do zfsroot with an attached drive to form a mirror, but meh, may as well use gmirror for that.


----------



## kungfujesus (Jun 26, 2009)

ahhh, just now noticed you didn't put /usr /usr/bin/ /sbin and /usr/sbin on there.  Whoops.  I suppose I could do that.


----------



## aragon (Jun 27, 2009)

I just installed 8.0 earlier today from the 200906 ISO snapshot.  So far all good, but I'm still busy building everything.  This is on a Dell XPS m1330 laptop.

The reason I made the jump was for USBv2 (and fixed umass/cam), mav@'s power saving improvements, and if_iwn(4).  New power saving is incredible - as good as Windows XP it seems!  Haven't tested USB much yet, and if_iwn is mostly working.  FreeBSD 7 on a modern laptop is bit frustrating so I'm really happy with 8 so far.


----------



## DrJ (Jun 27, 2009)

Does suspend and resume work?


----------



## aragon (Jun 27, 2009)

DrJ said:
			
		

> Does suspend and resume work?


Sort of.  System comes back up, Xorg still works, but network cards are dead and I can't suspend a second time.

Unloading the network modules prior to a suspend might help, but I'll need to setup a custom kernel to test.  Stay tuned...


----------



## aragon (Jun 27, 2009)

FYI, I thought I'd want to use suspend/resume in 8.0, but when I saw how quickly it boots I'm not sure I'll bother.  Resuming from suspend takes a bit of time for everything to settle anyway, and for a bit extra I can have a fresh boot.

For me, 8.0 kernel loads in 14 seconds, and after that userland loads in another 3 seconds, and Xorg another 7 seconds.  I think I can shave a couple seconds off the kernel load time with a custom compile.


----------



## DrJ (Jun 27, 2009)

aragon said:
			
		

> For me, 8.0 kernel loads in 14 seconds, and after that userland loads in another 3 seconds, and Xorg another 7 seconds.



That's impressive.  I've not heard that about 8.  For my desktops, this of course does not matter since they are never turned off.  For a laptop, though, it does make a difference.


----------



## wonslung (Jun 27, 2009)

SirDice said:
			
		

> IF you're on xDSL try to cut down your upload speed. Uploading close to the maximum of your connection seems to seriously impact download speeds.



no, i have cable.  I've had a perfect setup for months.  I hopnesty think comcast is throttling me.  I've got a freebsd router (well, really it's pfsense, which is what got me using freebsd in the first place) and i've had it set to traffic shape for months.  The problem is this:

Even if i start just 1 torrent, not even downloading fast, my ping goes up to about 1500 ms instead of around 40ms when i don't run a torrent.  It's like a night and day difference.  Something is SERIOUSLY wrong.  I orignally thought this was due to me switching the server to freebsd because that's when it started but when i think back, it also coincided with an ip address change.  My outgoing ip changed around the same time.  I think comcast has started some sort of aggressive anti torrent traffic shaping in my area.  I've had them out to "fix" my problem and they are due to come out again tomorrow so we'll see.  It's pretty ridiculous.  If i go to http://www.speedtest.net and test without a single running torrent my results are




now let me start a single torrent and test again




notice the difference in ping?  that's the problem i'm having.

The top speed isn't that big of a deal but the ping is killing me.

And right now it's actually not nearly as bad as it's been....tonight it's actually a lot better...so maybe it's something they are working on.

oh, and btw, this torrent hasn't even started uploading yet...so the difference in upload makes no sense really.


----------



## oliverh (Jun 27, 2009)

By the way,

>Start Code Freeze for the 8.0-RELEASE release cycle.

http://lists.freebsd.org/pipermail/svn-src-all/2009-June/011542.html


----------



## wonslung (Jun 28, 2009)

my internet ended up getting fixed today.
I'm stoked


----------



## DutchDaemon (Jun 28, 2009)

What does 'getting fixed' mean? Someone connected the pipes?


----------



## wonslung (Jun 28, 2009)

Yah, they unclogged the tubes.

apparently the Internet is NOT a big truck.


----------



## aragon (Jul 3, 2009)

aragon said:
			
		

> Unloading the network modules prior to a suspend might help, but I'll need to setup a custom kernel to test.  Stay tuned...


Sadly, my hopes were incorrect.  Suspending my system breaks both my network devices - if_bge and if_iwn.  Some USB devices fail to come back up too.  At least it's half working, though.


----------



## fronclynne (Jul 3, 2009)

*I need to (not)write a short story about that.*



			
				aragon said:
			
		

> Sadly, my hopes were incorrect.  Suspending my system breaks both my network devices - if_bge and if_iwn.  Some USB devices fail to come back up too.  At least it's half working, though.


I'm just typing "out of my posterior" so to speak, but I had heard that suspend/resume & SMP do not play well together.  My experience was that it is not worth the hassle, what with powerd(8) working quite well (powerd_flags=" -a hiadaptive -b adaptive") and boot times being trivial (& built-in session managers for all the applications that matter as far as that goes).

Maybe, some day far in the future when we're ruled by angry robots who whip us for their passionless, but still sadistic pleasure, it will become important.  Hopefully I won't live that long.


----------



## aragon (Jul 3, 2009)

Historically in FreeBSD, yes, SMP suspending has been impossible.  It used to leave your system completely unusable.  That changed a while ago and it does come back up now.  I'm guessing more work just needs to be done to get all drivers suspend friendly.  If Windows can do it... 

My boot times are good, so this isn't a major hassle for me.  Like you said, there are other things that can be done to save power, and for the rest nothing beats turning off completely.


----------



## aragon (Jul 3, 2009)

aragon said:
			
		

> For me, 8.0 kernel loads in 14 seconds, and after that userland loads in another 3 seconds, and Xorg another 7 seconds.  I think I can shave a couple seconds off the kernel load time with a custom compile.


Looks like I shaved off a second with latest code from HEAD and a custom kernel - 23 seconds from the boot loader to the Xorg/XDM login screen.  This is on a laptop with Core 2 Duo 2.5 GHz, 2 GB RAM, and 7200 RPM drive.  Happiness.


----------



## lme@ (Jul 6, 2009)

Resume & SMP only works on amd64 at the moment.


----------

