NETGEAR is aware of a growing number of phone and online scams. To learn how to stay safe click here.
Forum Discussion
zfil
Jul 14, 2008Aspirant
Subversion : some progress
Hello
I've managed to build a working subversion server :
wget http://subversion.tigris.org/downloads/ ... 5.0.tar.gz
wget http://subversion.tigris.org/downloads/ ... 5.0.tar.gz
First untar both previously downloaded tgz.
cd subversion-1.5.0/zlib
./configure && make test && make install
cd ..
./configure --build=sparc-linux --enable-all-static --with-ssl --without-serf --with-zlib=/usr/local
make
make check
make install
56 tests out of 56 must run successfully.
The key is to build static otherwise svn and svnsync command coredump ...
The problem now is that the subversion server is very very slow, it is not a cpu problem, more a networking I think (the cpu is idle).
I'm using svnserve (svnserve -d), it is my usual setup on other platform and I never experienced any slowness (but it wasn't svn 1.5).
I've managed to build a working subversion server :
wget http://subversion.tigris.org/downloads/ ... 5.0.tar.gz
wget http://subversion.tigris.org/downloads/ ... 5.0.tar.gz
First untar both previously downloaded tgz.
cd subversion-1.5.0/zlib
./configure && make test && make install
cd ..
./configure --build=sparc-linux --enable-all-static --with-ssl --without-serf --with-zlib=/usr/local
make
make check
make install
56 tests out of 56 must run successfully.
The key is to build static otherwise svn and svnsync command coredump ...
The problem now is that the subversion server is very very slow, it is not a cpu problem, more a networking I think (the cpu is idle).
I'm using svnserve (svnserve -d), it is my usual setup on other platform and I never experienced any slowness (but it wasn't svn 1.5).
41 Replies
Replies have been turned off for this discussion
- steverweberAspirantGood job!! best SVN news in a long time.
If svnserve is slow perhaps, you could try using (http: https:) libapache2-svn.
I think apache does not use svnserve. I could be wrong :(.
Once the slow bug is solve..
It would be grate if the updated binaries could be added to apt-get for everyone to enjoy..
keep up the good work :) - zfilAspirantOkay
I think I've found the problem ...
The slowness is due to /dev/random that is VERY slow on this machine.
# dd if=/dev/random bs=1k count=1 >/dev/null
0+1 records in
0+1 records out
9 bytes transferred in 16.719820 seconds (1 bytes/sec)
Okay I can confirm this is really the problem ...
I've replaced /dev/random as /dev/urandom and now it's very fast.
I'm recompiling apr to use /dev/urandom so ...
:) - steverweberAspirantNice find!
I wounder if dev/random should be symbolic linked to urandom, so all dependent programs get a boost. Well until dev/random is fixed.
I don't see the less random dev/urandom as a large security problems.
Is their some ReadyNAS dev around that can add your bins as some sorta plug-in for us all to use?
don't get me wrong, cross compiling is fun... but it takes CPU cycles away from the video games and video watching. - JimmyB1AspirantYes, could it be packaged in a nice addon (.bin) now the add-on API has been released?
- rocket15AspirantGood news...
Did you use the following configure statement?
./configure --build=sparc-linux --enable-all-static --with-ssl --without-serf --with-zlib=/usr/local --with-devrandom=/dev/urandom - samclementAspirantSounds pretty exciting... will you keep us updated on this thread?
- zfilAspirantYeah don't worry I'm a little busy but I will provide a tarball with the working binaries.
Then I will work on an addon version.
Philippe - _mjAspirantgreat to hear zfil, having a svn server running on the ReadyNAS seems like a perfect fit
- Dogberry1Aspirant
zfil wrote: The slowness is due to /dev/random that is VERY slow on this machine.
"When the entropy pool is empty, reads from /dev/random will block until additional environmental noise is gathered. (Source: Linux Programmer's Manual, section 4)"
So apparently the environmental noise density contributing to the entropy pool is very slight on these boxes. Using /dev/urandom seems like a perfectly acceptable alternative here.
/* sidebar:
I believe it was Robert Coveyou who said "The generation of random numbers is far too important to be left to chance." But my favorite geekjoke about random numbers is in the form of a cartoon depicting a random-number generator function like this:
int getRandomNumber()
{
return 4; // chosen by fair dice roll
// guaranteed to be random
}
*/ - gromeenAspirantDisclaimer: I'm new to ReadyNAS and linux.
I'm trying this with the latest subversion 1.5.1 files. This is what I've done so far:
1. started with a fresh factory default ReadyNAS (RAIDiator 4.1.3-T136 [1.00a146] in X-RAID)
2. downloaded EnableRootSSH and APT from here
3. installed those .bin files via FrontView, System>Update>Local
4. logged into my ReadyNAS via SSH (putty)
5. apt-get update
6. apt-get install nano (I'm not a vi wizard)
7. apt-get install gcc
8. wget http://subversion.tigris.org/downloads/subversion-1.5.1.tar.gz
9. wget http://subversion.tigris.org/downloads/subversion-deps-1.5.1.tar.gz
10. tar xvzf subversion-1.5.1.tar.gz
11. tar xvzf subversion-deps-1.5.1.tar.gz
12. rm *.gz (why keep the tarballs?)
13. cd subversion-1.5.1/zlib/
14. ./configure && make test && make install
This is where I get stuck. Here is the error dump:Checking for gcc...
Building static library libz.a version 1.2.3 with gcc.
Checking for unistd.h... No.
Checking whether to use vs[n]printf() or s[n]printf()... using s[n]printf()
Checking for snprintf() in stdio.h... No.
WARNING: snprintf() not found, falling back to sprintf(). zlib
can build but will be open to possible buffer-overflow security
vulnerabilities.
Checking for return value of sprintf()... No.
WARNING: apparently sprintf() does not return a value. zlib
can build but will be open to possible string-format security
vulnerabilities.
Checking for errno.h... No.
Checking for mmap support... No.
gcc -O3 -DNO_snprintf -DHAS_sprintf_void -DNO_ERRNO_H -c -o example.o example.c
example.c:8:19: stdio.h: No such file or directory
example.c:12:22: string.h: No such file or directory
example.c:13:22: stdlib.h: No such file or directory
example.c: In function `test_compress':
example.c:67: error: `stderr' undeclared (first use in this function)
example.c:67: error: (Each undeclared identifier is reported only once
example.c:67: error: for each function it appears in.)
example.c: In function `test_gzio':
example.c:99: error: `NULL' undeclared (first use in this function)
example.c:100: error: `stderr' undeclared (first use in this function)
example.c: In function `test_deflate':
example.c:182: error: `stderr' undeclared (first use in this function)
example.c: In function `test_inflate':
example.c:225: error: `stderr' undeclared (first use in this function)
example.c: In function `test_large_deflate':
example.c:260: error: `stderr' undeclared (first use in this function)
example.c: In function `test_large_inflate':
example.c:320: error: `stderr' undeclared (first use in this function)
example.c: In function `test_flush':
example.c:357: error: `stderr' undeclared (first use in this function)
example.c: In function `test_sync':
example.c:399: error: `stderr' undeclared (first use in this function)
example.c: In function `test_dict_deflate':
example.c:438: error: `stderr' undeclared (first use in this function)
example.c: In function `test_dict_inflate':
example.c:480: error: `stderr' undeclared (first use in this function)
example.c: In function `main':
example.c:524: error: `stderr' undeclared (first use in this function)
make: *** [example.o] Error 1
Any ideas what I'm missing? It looks like I'm missing some important header files (stdio, string, stdlib). How do I get those? And where do I put them?
Also, if I can get the above working and continue on with the subversion installation, what are the steps needed to replace /dev/random with /dev/urandom in apr?
zfil? rocket15? Bueller? Anyone?
Much thanks!
Related Content
NETGEAR Academy
Boost your skills with the Netgear Academy - Get trained, certified and stay ahead with the latest Netgear technology!
Join Us!