Reply
 
Thread Tools Display Modes
  #1  
Old 05-02-2008, 05:26 PM
OlRoy OlRoy is offline
Junior Member
 
Join Date: May 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default Updating FreeBSD 7.0 with csup
I think I'm beginning to understand how to keep FreeBSD updated, but I have some questions...

1.) Does csup just put the source tree in /usr/src, or does it actually compile it and update your system too?

2.) How big is the source tree?

3.) What's the best way to update your kernel source code to the latest version before recompiling it?

If anyone could shed some light on these questions, I'd appreciate it.
Reply With Quote
  #2  
Old 05-02-2008, 06:51 PM
TerryP TerryP is offline
Senior Member
 
Join Date: Nov 2005
Location: Ga. USofA
Posts: 7,906
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to TerryP Send a message via AIM to TerryP Send a message via Yahoo to TerryP
Default Re: Updating FreeBSD 7.0 with csup
1/ csup only fetches the files, the software to update the system is already installed.

2/ I'm not sure any more, I'd guess 200-450MB.

3/ csup (the pc-bsd system tool is just a front end)


As far as only fetching the kernel sources, you could do that through playing with your supfile but if recompiling the kernel is in your plans I believe you need the full source tree not just the kernel sources.


Unlike Linux which uses a separate userland (GNU), FreeBSD kernel and userland are like PB&J from day one. Updating the kernel to a new version and not updating the userland the new version also can have subtle 'issues' in how some programs function.
Reply With Quote
  #3  
Old 05-02-2008, 07:33 PM
OlRoy OlRoy is offline
Junior Member
 
Join Date: May 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default Re: Updating FreeBSD 7.0 with csup
Thanks for the reply. When you say the software to update FreeBSD 7.0 is already installed, what's it called?
Reply With Quote
  #4  
Old 05-02-2008, 08:13 PM
TerryP TerryP is offline
Senior Member
 
Join Date: Nov 2005
Location: Ga. USofA
Posts: 7,906
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to TerryP Send a message via AIM to TerryP Send a message via Yahoo to TerryP
Default Re: Updating FreeBSD 7.0 with csup
In reality it can consist of just about any thing in the base system and the source tree.

In actuality, from the side that we see of it is

csup -- fetch source

make -- automate building source

mergemaster -- help us merge config files




Generally updating the system the 'freebsd way' looks some thing like this:

Code:
vi /the/supfile
  ...                        # make sure things are set to get the right source code
csup /the/supfile            # older versions used 'cvsup' which was not in the base system; usage is the same.
  ...                        # nice coffee break while it downloads new files
$PAGER /usr/src/UPDATING     # read updating notes
make buildworld              # build new userland
make buildkernel             # build new kernel
make installkernel           # install kernel
reboot
  ...                        # boot into SINGLE USER mode
make installworld            # install new userland
mergemaster -viU             # interactively merge config files: read the manual for option specs, 
                             # I always use -v because I rarely use mergemaster
reboot
  ...                        # let's the system start clean

before starting it's generally a good idea to make a back up the files in /etc before starting just in case you screw up some thing in the mergemaster phase (I usually create a .tar or. zip file of /etc just in case).

After the builds done you can delete all the files within /usr/obj - which stores files created during the build process.


There's a new freebsd-update program that can do more of this stuff manually I think but I'm not sure if the one in FreeBSD 6.3-Release (which PC-BSD 1.5.x is based on) is able to update the system to 7.0-Release.


A version of PC-BSD based on FreeBSD 7 is in Alpha testing now, alpha meaning highly expiremental phase looking for bugs involved before making it easy for people to update PC-BSD ;-)


I've also manually taken a PC-BSD machine to FreeBSD 7.0-Release before, it's not hard but can be time consuming. One of these days I'm going to try taking a FreeBSD 7 isntall to a Pc-BSD one manually, it'll be interesting.
Reply With Quote
  #5  
Old 05-02-2008, 09:34 PM
OlRoy OlRoy is offline
Junior Member
 
Join Date: May 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default Re: Updating FreeBSD 7.0 with csup
I think I'm understanding it better now. So if in my csup config I have "src-all tag=RELENG_7_0" for just the security/critical updates, is there a way for me to not install an update if it causes a problem when I test the patch on a test network?
Reply With Quote
  #6  
Old 05-02-2008, 11:36 PM
TerryP TerryP is offline
Senior Member
 
Join Date: Nov 2005
Location: Ga. USofA
Posts: 7,906
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to TerryP Send a message via AIM to TerryP Send a message via Yahoo to TerryP
Default Re: Updating FreeBSD 7.0 with csup
Not entirely sure what you mean.

When it comes to the various security notices sent out by FreeBSDs security team, you're not obligated to carry out the upgrade process. If it causes any issues on one of your test machines, no need to spread it on to stable ones.


Most I've read, give instructions that are singular to patching the problem at hand rather then needing the above ^^ listed method of updating the system. What I listed is what's typically used for more larger scale updates then a single patch op.



I personally skip ones that do not apply to my situation until my next csup/buildworld/buildkernel op. PC-BSD's also getting much better with these issues. The last one for SSH, PC-BSDs update manger updated it about 2 days after I adjusted my SSH services based on their work-around notes.


However, *generally speaking* things that warrant security advisories being mailed along with fix instructions. usually get committed to the source tree. So they will likely hit every machine that gets updated the usual way unless they are not updated, e.g. remain at 7.0-Release with manual patches while skipping a transition to 7.1-Release when it hits. Although that odds of needing that are probably quite slim, it's always possible should it be necessary to do so.


One thing I do like vary much is the honest no shit assessments of what branches are affected when they do issue advisories.
Reply With Quote
  #7  
Old 05-03-2008, 12:09 AM
OlRoy OlRoy is offline
Junior Member
 
Join Date: May 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default Re: Updating FreeBSD 7.0 with csup
Yeah to clarify, my question was since your previous post appeared to be for large updates fixing multiple bugs, what do you do if you need to be more granular and omit a single patch that negatively impacts your system.

I guess you have to just apply single patches manually by monitoring the FreeBSD Security Advisories?
Reply With Quote
  #8  
Old 05-03-2008, 12:34 AM
TerryP TerryP is offline
Senior Member
 
Join Date: Nov 2005
Location: Ga. USofA
Posts: 7,906
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to TerryP Send a message via AIM to TerryP Send a message via Yahoo to TerryP
Default Re: Updating FreeBSD 7.0 with csup
That would likely be the easiest course of action.


But it also means it probably would be problematic to ever update to a future release or stable branch (e.g. 7-Stable to 8-Stable when there is one, etc) if the 'skipped' patch causes problems with your systems.


There's no limit to what you can do really, I'd rather hope that instances where you would have to do some thing like this would be quite rare other then some pieces of hardware.


The advisories generally have instructions, poking around the Makefile system and the folders in the source tree would likely yield variafialbe notes on whats what as far as make targets go (FreeBSD uses a recursive make build strategy last I noticed).
Reply With Quote
  #9  
Old 05-03-2008, 12:50 AM
OlRoy OlRoy is offline
Junior Member
 
Join Date: May 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default Re: Updating FreeBSD 7.0 with csup
That's good, I think I know enough to load FreeBSD in VMware and practice patching it now. Thanks for your help!
Reply With Quote
  #10  
Old 05-03-2008, 05:48 PM
TerryP TerryP is offline
Senior Member
 
Join Date: Nov 2005
Location: Ga. USofA
Posts: 7,906
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to TerryP Send a message via AIM to TerryP Send a message via Yahoo to TerryP
Default Re: Updating FreeBSD 7.0 with csup
Cheers
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
updating from 7.1 to 7.1.1 bsdaddict General Questions 0 07-21-2009 05:05 PM
CSup - Portsnap question vinoman General Questions 4 05-05-2008 10:26 PM
csup instead of cvsup antik Tips and Tricks 5 03-01-2007 06:17 AM
Updating RC2 to 1.1 DrJ General Questions 28 06-16-2006 03:29 AM
Updating from RC1 to RC2 mikew777 General Bug Reports 3 02-10-2006 12:01 PM


All times are GMT. The time now is 07:45 PM.


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.

Copyright 2005-2010, The PC-BSD Project. PC-BSD and the PC-BSD logo are registered trademarks of iXsystems.
All other content is freely available for sharing under the terms of the Creative Commons Attribution License.