Help - Search - Members - Calendar
Full Version: Freebsd And Ns I Got It Working
Unknown Worlds Forums > Natural Selection > Natural Selection Discussion > General Server Discussion > Linux Server Support
UgLyPuNk
Well i have got it running

it is using about 13% of a xp 2100 when idle but it is running what i did....

Clean install of freebsd 4.8 with linux compat
I then cvsup'ed ran portupdate etc to get 100% up to date

I then deinstalled the Linux_base Port and installed the new linux_base-8 port


I installed hlds 3.1.1.1d and ns with the 3.1.1.1 fix so

i then found it keeped saying that it couldn't find lib/libnoversion.1.so although it was there

then came the wierd and wonderful fix....

i mounted linproc, bang it started running then installed metamod and admin no problems
Still haven't tested it under load but it isn't crashing


zippy
keep me posted coz i have seen server's with freebsd, windows, redhat or debian, to rent, not with ns on but you know what i mean tounge.gif

zippy
verbose
Excellent thinking. Hindsight being 20/20, I can't believe I didn't try this. Thanks smile.gif

I confirm the following working (can join and run around, no load test yet) combinations:

FreeBSD 4.8-RELEASE
HLDS 3.1.1.0
linux_base-8-8.0_1

FreeBSD 4.8-RELEASE
HLDS 3.1.1.1d with replacement ns_i386.so
linux_base-8-8.0_1

If I get around to it tonight or tomorrow, I'll try linux_base-7.1_5

For those FreeBSD users who are unfamiliar with linprocfs, it emulates the linux /proc filesystem. Do this as root:
CODE
mount_linprocfs linprocfs /compat/linux/proc

The command should produce no output if successful, kldstat will show "linprocfs.ko", and mount will obviously show the new filesystem.
UgLyPuNk
What is your cpu usage like
mine is very high xp2100 20 players 100% with a high ping

the wierd thing is it idles at between 10-20%

what about yours
joev
Wow! Amazing Kingsley....

Super work... and there was me thinking all along that it was library function clobbering in the STL/libc io interface.

No indication from the segfaults that it was missing /proc.... (sorry, I know very little about FreeBSD and the linux_base stuff otherwise I may have been more help.)

As for the CPU usage, I'm at a loss. Have you tried hlds_l 3.1.1.0 at all? (does it even work?)

You should note that high entity maps will always run heavy on cpu (bast and hera for example) but 100% of an XP 2100 is a bit much.

Is it possible to try 3.1.1.0 (You might want the un-official 'boffix' patch as well.) and see if that's similar?

joe.
funkboy
If you're having performance problems, first make sure you're running 4.8, then check out FreeBSD Kernel polling. (There's also a man page). Still testing it, but so far so good. Only works on uniprocessor systems for now due to the fascinating problems this could introduce on an SMP machine :-).
UgLyPuNk
unfortunatly im on a dual proc sad.gif

i might try 3.1.1.0

any chance of getting a redhat 8 gcc3 compile and see how that plays

or even a non optimized one something to play with, see what happens
Smufe
Yay, thanks for the info on FreeBSD. Unfortunately, I'm stupid, so I'm still not having luck. I'm just trying to get a normal half life server running, but I can't connect from outside. I think it probably has to do with firewall settings, so I've been messing with ipf rules. I'm still not having any luck though. Can someone who sucessfully runs a FreeBSD server post the relevant part of their ipf rule file to help me out? I've found a couple of lists of ports that need to be open, but not luck. I really don't have much of an idea of what I'm doing, so that doesn't help.

Smufe
verbose
Unless your FreeBSD machine is a router or bridge that's protecting other machines, you probably don't need to run a firewall on it. If you only run the services that you'll be using (FTP, SSH, HLDS, etc), and you're going to poke holes in the firewall for those anyway, then your firewall is doing exactly nothing smile.gif

With that said, I do run ipfw on every single FreeBSD machine I deploy, but with an "open" configuration. That way, if some kiddie decides it's fun to make thousands of connections to your XYZ service per minute, effectively denying legitimate connections, it's probably only one swift command to shut him down.

You may want to check out using ipfw instead of ipf. The syntax is a little more "friendly", and there's more native documentation available. If you're dead set on ipf, post your config and we should be able to help you with it.
verbose
Weedkiller- posted in another thread that his FreeBSD servers ran fine with mp_uplink "0", but would crash with mp_uplink "1". Sure enough, I unmounted linprocfs, and had the same results. With linprocfs remounted, mp_uplink "1" works. Therefore, the section of code that needs the Linux proc filesystem is triggered in some way by mp_uplink. Hope that helps you Dev types smile.gif
Murdock
I am having a problem doing this fix with FreeBSD 4.8-RELEASE. When I go to mount the linprocfs it gives me an error:

root#mount_linprocfs linprocfs /compat/linux/proc
mount_linprocfs: vfsload(linprocfs): Exec format error

I deinstalled the original linux_base, did cvsup, and installed linux_base-8. After installing 8, I get the previous error. I'm not sure what else there is to do. Any help would be great.

Thanks For Your Help
verbose
QUOTE ([TEGZ]Murdock @ Sep 16 2003, 05:29 PM)
root#mount_linprocfs linprocfs /compat/linux/proc
mount_linprocfs: vfsload(linprocfs): Exec format error

Are any of your filesystems mounted with the "noexec" option?

Also, make sure that these two files are mode 555:
/modules/linprocfs.ko
/sbin/mount_linprocfs
Murdock
I checked both files and after chmod 555 both of them, I get the same error when trying to mount_linprocfs. Not sure how to tell if it was mounted w/ noexec but i presume its not because it is a fresh install of FreeBSD. Any other options?
verbose
'Exec format error' comes from an ENOEXEC, which is usually caused by a program not being executable due to permissions, mount settings, and so forth.

mount will show the options each filesystem is tagged with.

What's the output of each of these
kldstat
ls -loa /compat/linux/proc
Murdock
here are the outputs of the commands:

$ mount
/dev/ad0s1a on / (ufs, local)
/dev/ad0s1e on /boot (ufs, local, soft-updates)
procfs on /proc (procfs, local)

$ kldstat
Id Refs Address Size Name
1 2 0xc0000000 40000000 kernel
2 1 0xc2342000 15000 linux.ko

$ ls -loa /compat/linux/proc
total 4
drwxr-xr-x 2 root wheel - 512 Feb 6 1996 .
drwxr-xr-x 12 root wheel - 512 Sep 16 17:21 ..
verbose
try kldload linprocfs and check kldstat to see if it loads. I have a hunch it's failing to load the kernel module, and that's why the mount blows up.
Murdock
Ok that didn't seem to work looks like your right

root# kldload linprocfs
kldload: can't load linprocfs: Exec format error

so is there any fix?
verbose
Yeah, you probably just need to rebuild the linprocfs module (or all modules is just as easy); it seems to not be compatible with the kernel you're running. See the FreeBSD handbook. You may just want to upgrade to RELENG_4_8 (the security-patches branch) while you're at it. Or, just rebuild the kernel and modules if you don't want to tackle the whole world.
Synthetic
Metamod version 1.17 Copyright © 2001-2003 Will Day <willday@metamod.org>
Metamod comes with ABSOLUTELY NO WARRANTY; for details type `meta gpl'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `meta gpl' for details.

Segmentation fault
Deprecated bfd_read called at /usr/src/gnu/usr.bin/binutils/gdb/../../../../contrib/gdb/gdb/dbxread.c line 2627 in elfstab_build_psymtabs
Deprecated bfd_read called at /usr/src/gnu/usr.bin/binutils/gdb/../../../../contrib/gdb/gdb/dbxread.c line 933 in fill_symbuf

"/usr/home/myaccount/hlds_l/./hlds_i686.core" is not a core dump: File format not recognized
debug.cmds:1: Error in sourced command file:
No stack.
email debug.log to linux@valvesoftware.com

I am running a FreeBSD 4.9-STABLE system. I can get it to start with out metamod. I have been able to run CS with meta mod sucessfully. If anybody can help me. Please let me know. smile.gif
Lumpy
If this is for NS 3.0 then you need to do 1 of three things.

a) Add +localinfo mm_gamedll dlls/ns_i386.so to the end of your startup command line

b)Create a config.ini file in your metamod folder where your plugins.ini file is, and enter gamedll dlls/ns_i386.so into this file

c) Get a fixed metamod version from http://www.modns.org this would be your best bet. You'll most likely need TromPT's version as it works with an older glibc
Synthetic
The first one worked, Thanks. smile.gif
Jeremiad
Enyone have tested with NetBSD? :o
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.