Register for the iXsystems Community to get an ad-free experience and exclusive discounts in our eBay Store.

Guide: How to Build FreeNAS (Part 2: Install and Build FreeNAS)

Status
Not open for further replies.

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
9,078
No way! Both of you got the same error! Me too! I submitted a ticket for it early this morning. Something is broken and it's not either of you. Others have the problem too.
 

jerrybme

Member
Joined
Sep 28, 2011
Messages
40
No way! Both of you got the same error! Me too! I submitted a ticket for it early this morning. It has nothing to do with the build but has everything to do with the devs putting in changes with testing them out. I suspect 8196 killed it.

What was the last build number either of you completed, higher than 8196? I would help to locate the problem.
I've had the same issue. I'm guessing it was the port change from netatalk 2.2 to 2.2.1 see this update.

Hate wasting all the time to compile only to have it error out :mad:

r8193 was my last successful build. I may try and edit the patch to see if I can get it compile while we wait for the devs to fix it.
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
9,078
The fix has been rolled in, a fresh build will solve the problem. It was related to r8196 but it wasn't the developers fault. Looks like it was a poor porting on FreeBSD if I read the problem correctly. I'm gonna start another build in a few hours and see how it turns out.
 

jerrybme

Member
Joined
Sep 28, 2011
Messages
40
The fix has been rolled in, a fresh build will solve the problem. It was related to r8196 but it wasn't the developers fault. Looks like it was a poor porting on FreeBSD if I read the problem correctly. I'm gonna start another build in a few hours and see how it turns out.
Too bad I didn't wait a bit longer, just finished compiling 8195 :smile:
 

Tekkie

Senior Member
Joined
May 31, 2011
Messages
344
How does one create the Upgrade file? I am not really interested in doing a 'clean' install.
 

ProtoSD

Dedicated Sage
Joined
Jul 1, 2011
Messages
3,353
When you compile the build, the GUI upgrade file is the larger of the '.xz' files.
 

Tekkie

Senior Member
Joined
May 31, 2011
Messages
344
Ah ok... thanks for that info, currently building the vmware tools as I will try building through a shared VMWare folder...
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
9,078
A virtual machine is the best way to go when building FreeNAS.
 

Tekkie

Senior Member
Joined
May 31, 2011
Messages
344
All is setup however when I run the do_build.sh script it says it cannot find FreeBSD/src I am pretty sure I have every single source file installed... what am I missing?

Could it be the missing cvsup? :)
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
9,078
What directory are you running the script in? You should be in /usr/local/freenas/trunk (or if building form a branch /8.0.2).

If you don't have cvsup set you will not download all the port/source files which would be obvious because it takes time to download those plus I believe it's a different error message. My bets are you're in the wrong directory.
 

Tekkie

Senior Member
Joined
May 31, 2011
Messages
344
[root@FN8_Builder /usr/local/freenas/trunk]# pwd
/usr/local/freenas/trunk
[root@FN8_Builder /usr/local/freenas/trunk]# build/do_build.sh
grep: /usr/local/freenas/trunk/FreeBSD/src-patches: No such file or directory
Applying patch freebsd-ahci.patch...
cd: can't cd to FreeBSD/src
[root@FN8_Builder /usr/local/freenas/trunk]#

directory is right.

PS. The trunk README says put the sources in /usr/local/trunk.
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
9,078
@ Tekkie,
I don't know what happened to my reply to you but I swear I posted it this morning. Here is is again...

Since I don't know what you have do to compile the program here are a list of steps that work.

Code:
svn co https://freenas.svn.sourceforge.net/svnroot/freenas/trunk
cd trunk
setenv FREEBSD_CVSUP_HOST cvsup10.freebsd.org
sh build/do_build.sh
I have a new fbuild script I'm testing right now (you can make one change and it may throw off something else), It does a better cleanup than the previous version by removing locked file that may occur during a failed build attempt. I recommend using this script if you still are having problems and you can look at it for clues. I'll upload it once it's verified to work for a normal build.

EDIT: Uploaded new script on first posting this thread. Just to let you know, something is up with the build process again, I've submitted another ticket against it and it happens every couple of weeks that it gets broken. Hopefully it's something simple to overcome.
 

Tekkie

Senior Member
Joined
May 31, 2011
Messages
344
I am gong through the do_build.sh script and found one bug :) the supfile is not regenerated when you 'move' the source tree... can cause some interesting problems... ;)
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
9,078
Try building r8394, should work. Looks like severe modifications in change 8395 & a little correction in change 8396, on a Friday of course where they just leave it broken.

EDIT: Just built r8394 without issue.
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
9,078
The FreeNAS do_build.sh works as coded, just finished r8400. I recall one of the developers stating they used bash. Well FreeBSD doesn't start with bash so it has to be added and then set as the default. I've updated the setup of the VM to reflect properly installing bash.

Sorry for all the turmoil I caused by simply not understanding bash was required. I will be requesting the README file which has instructions on how to build is updated to reflect using bash if it will not be cross compatible.

EDIT: I've updated the fbuild.sh script to check for bash shell and to toss an error message if it's not.
 

Skaven

Member
Joined
Oct 25, 2011
Messages
31
u mist a space between set and env


b. Type “setenv FREEBSD_CVSUP_HOST cvsup3.freebsd.org” and Enter.


[root@Virre /usr/local/freenas/trunk]# setenv FREEBSD_CVSUP_HOST=cvsup1.freebsd.org
su: setenv: command not found
[root@Virre /usr/local/freenas/trunk]# set env FREEBSD_CVSUP_HOST=cvsup1.freebsd.org
[root@Virre /usr/local/freenas/trunk]#
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
9,078
u mist a space between set and env


b. Type “setenv FREEBSD_CVSUP_HOST cvsup3.freebsd.org” and Enter.


[root@Virre /usr/local/freenas/trunk]# setenv FREEBSD_CVSUP_HOST=cvsup1.freebsd.org
su: setenv: command not found
[root@Virre /usr/local/freenas/trunk]# set env FREEBSD_CVSUP_HOST=cvsup1.freebsd.org
[root@Virre /usr/local/freenas/trunk]#

There is no equal sign between 'CVSUP-HOST' and 'cvsup1.freebsd.org' when using setenv.
"setenv FREEBSD_CVSUP_HOST cvsup1.freebsd.org" is proper.

EDIT: Guess you're right, doesn't work with BASH at all. You need to use C Shell which is the default when you install FreeBSD. Well the ticket got reopened stating there was a flaw in the scripting for do_build.sh so guess we can revert back to C Shell.

EDIT: If you happen to have installed bash and changed your shell to bash, to revert it back to C Shell just enter 'chsh -s csh', log off and log back in. do_build.sh getting broken so much is driving me to drink (more).
 

froes

Newbie
Joined
Dec 1, 2011
Messages
1
can i install the compiled freeNAS on top of a regular freebsd installation ?
extract some of the .xz
create a tbz to be installed maybe ?

thanks in advance guys !!!
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
9,078
can i install the compiled freeNAS on top of a regular freebsd installation ?
extract some of the .xz
create a tbz to be installed maybe ?

thanks in advance guys !!!
I don't know but this is not the correct thread to post this type of question. Please create a new thread under Help & Support / Installation and then delete your posting here please. The new posting would get you the correct group you desire.

Thanks,
Mark
 
Status
Not open for further replies.
Top