Re: [gentoo-user] IPtables question

2007-02-02 Thread Pawel Kraszewski
Dnia środa, 31 stycznia 2007, James Colby napisał:

 I have a small home server that I have connected to the internet
 through a linksys router and cable modem.  The linksys router is
 currently forwarding all ssh traffic to my gentoo box.  What I would
 ^

Take note, that forwarded traffic (it is DNAT-ed in Linksys) would appear on 
your host as originating from your router. Original source address is 
stripped by router's NAT.

Ergo, you need source address filtering in your router.


-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] IPtables question

2007-02-02 Thread Pawel Kraszewski
Dnia piątek, 2 lutego 2007, Hans-Werner Hilse napisał:
 Nope, just the target Adress is rewritten (by routing). DNAT is
 Destination NAT! I.e. the target IP of the packet is rewritten. Since
 the Linksys is the default gateway, packets can keep their source IP
 address. Of course, the source MAC address will be rewritten to the
 router's -- but that's got nothing to do with NAT but routing instead.

Jeee, I'm terrible sorry. My only excuse is that it was written without the 
morning coffee... Of course SNAT rewrites source IP and DNAT destination IP, 
and port forwarding uses DNAT. Once more, sorry for confusion - my mind was 
somehow floating around proxying not forwarding.

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] How can I emerge a program with debugging options?

2007-01-15 Thread Pawel Kraszewski
Dnia poniedziałek, 15 stycznia 2007 10:13, qfpvajdy napisał:
 Hello,

 I would like to emerge a program with debugging options CFLAGS=-g and
 without strip at the end of the build. I know that I could do this:
 $ export CFLAGS=-g; emerge mypackage

Take a look at:

http://www.gentoo.org/proj/en/qa/backtraces.xml


P.S.  Pls. correct your signature separator. It should be 
dash-dash-SPACE-enter. You have just dash-dash-enter.

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] distcc

2007-01-07 Thread Pawel Kraszewski
Dnia niedziela, 7 stycznia 2007 03:45, sean napisał:

   Your steps are obviously a bit different then those listed here.
 http://www.gentoo.org/doc/en/cross-compiling-distcc.xml

 So you are stating just emerge crossdev, the run crossdev -t
 and from the point where the web page states Here is what you want to
 do: (1.2) follow the instructions you listed here, rather then the web
 page?

I don't have crossdev at all... AMD64 gcc can simply compile code for IA32 
architecture (forced by -m32 parameter in wrapper).

My note is a total replacement of 
http://www.gentoo.org/doc/en/cross-compiling-distcc.xml for 
64-compiling-for-32 case.


-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] distcc

2007-01-06 Thread Pawel Kraszewski
Dnia piątek, 5 stycznia 2007 14:47, sean napisał:

 I am reading over the info on distcc so that I might be able to setup an
 older P4 1.3 Ghz system to have help compiling from my dual Opteron
 (amd64 mode).

 I only want the Opteron to help the P4, not the other way around, the
 Opteron does not need the help.

 Is that configurable as such?

   Thanks
   Sean

Well, http://wiki.kraszewscy.net/Cross_DistCC shows how to do it (in Polish, 
sorry).

In short:

---8X---[ setup for COMPILER machine (AMD64) ]---

1. make directory /opt/cross32/bin
2. make there a file i686-pc-linux-gnu-wrapper containing

  #!/bin/bash
  exec /usr/bin/x86_64-pc-linux-gnu-g${0:$[-2]} -m32 $@

3. make it executable
4. make soft links in that directory

 ln -s i686-pc-linux-gnu-wrapper gcc
 ln -s i686-pc-linux-gnu-wrapper g++
 ln -s i686-pc-linux-gnu-wrapper c++
 ln -s i686-pc-linux-gnu-wrapper cc
 ln -s i686-pc-linux-gnu-wrapper i686-pc-linux-gnu-gcc
 ln -s i686-pc-linux-gnu-wrapper i686-pc-linux-gnu-g++
 ln -s i686-pc-linux-gnu-wrapper i686-pc-linux-gnu-c++
 ln -s i686-pc-linux-gnu-wrapper i686-pc-linux-gnu-cc

5. copy /etc/init.d/distccd to /etc/init.d/distccd32

6. fix /etc/init.d/distccd32 to have

   TMPDIR=${TMPDIR} \
   PATH=/opt/cross32/bin \
   /sbin/start-stop-daemon –start –quiet –startas ${DISTCCD_EXEC} \

7. copy /etc/conf.d/distccd to /etc/conf.d/distccd32

8. fix /etc/conf.d/distccd to have

DISTCCD_OPTS=${DISTCCD_OPTS} --port 3664

---8X---[ end of setup for COMPILER machine (AMD64) ]---

Now you have two distccd daemons: 
* one at port 3632 for 32-bit distcompiling
* one at port 3664 for 64-bit distcompiling

At this point your Opterons will handle remote 32-bit compiling - you don't 
need to make any changes on P4 machine other than activating regular distcc.

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] Compiler error during qemu installation

2006-12-21 Thread Pawel Kraszewski
Dnia czwartek, 21 grudnia 2006 18:13, Rumen Yotov napisał:

 Hi,
 +1 for gcc-3.X.

 Just to add that maybe you'll have to use gcc-3.4.X for kernel
 compilation too, if you use kqemu USE-flag (as above).
 I compile the 'kernel'+all of qemu with 3.4.X

No, you don't need GCC3 to compile _kqemu_. kqemu communicates with QEMU via 
device and may be compiled by different version of GCC. Works fine for me.

So GCC3 for QEMU and GCC4 for kqemu and kernel.

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] ifconfig - SIOCSIFFLAGS: Cannot assign requested address

2006-12-11 Thread Pawel Kraszewski
Dnia poniedziałek, 11 grudnia 2006 18:34, Leandro Melo de Sales napisał:

 config_eth0=( 192.168.1.2 netmask 255.255.255.0
   192.168.1.3 netmask 255.255.255.0
   192.168.1.6 netmask 255.255.255.0
 )

Well, it is a design flaw to have 3 addresses in overaping networks. From what 
I recall you may use only one non /32 address in a network. If the 
requirement is not met, problems arise:

Problem: You want to broadcast to 192.168.1.255.
Question: From which of these addresses should it origin?

Problem: Someone else broadcasts to 192.168.1.255.
Question: Which of these addresses should catch it? One? All?


I was taught that configurations of multiple-ip-per-net should look like:

 config_eth0=( 192.168.1.2 netmask 255.255.255.0
   192.168.1.3 netmask 255.255.255.255
   192.168.1.6 netmask 255.255.255.255
 )

Only the first has a regular mask (and therefore is source and target for 
broadcasts) - the rest has /32 mask and is only valid for unicast 
communication.

AFAIK this is true for both multiple cards on single network and multiple 
aliases on single card.

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] OT - Finding my modem

2006-12-09 Thread Pawel Kraszewski
Dnia piątek, 8 grudnia 2006 23:18, Michael Sullivan napisał:

   05:01.0 Communication controller: U.S. Robotics Unknown device 2f00
   (rev 01)
   Subsystem: U.S. Robotics Unknown device 0113
   Flags: bus master, medium devsel, latency 32, IRQ 11
   Memory at ff90 (32-bit, non-prefetchable) [size=64K]
   I/O ports at bc00 [size=8]
   Capabilities: [40] Power Management version 2

Your modem definitely is NOT snd-intel8x0m device. Haven't found exact info 
(down to subsystem), but this _probably_ is HSF/HSFi-comatible modem 
(according to http://www.linuxant.com/drivers/hsf/index.php)

Give net-dialup/hsfmodem a try.

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] Gigabit NIC but only 100baseT/Full working

2006-12-05 Thread Pawel Kraszewski
Dnia poniedziałek, 4 grudnia 2006 22:49, Daniel van Ham Colchete napisał:

 I'm planing on using the eth1 ethernet with DRBD. My problem is that
 although the NICs support gigabit ethernet, they only negociate with
 100baseT/Full. I'm using a CAT-5E crossover cable between the servers.

I'm not 100% sure, but try a straight cable. I don't quite remeber, but this 
is due to that all 4 pairs are bi-directional and/or 1k cards are MDI/MDIX 
autosensing.

OTOH see http://www.ertyu.org/steven_nikkel/ethernetcables.html

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] How come my 'esearch' isn't updated when I emerge something until the next 'esync'?!

2006-11-16 Thread Pawel Kraszewski
Dnia piątek, 17 listopada 2006 07:27, Daevid Vincent napisał:
 I always found this annoying...

 How come when I emerge something, my 'esearch' isn't updated until the next
 time I do an 'esync'?

Because it is the way it is designed.

Well, it is a high time to switch from esearch to eix. Then you update portage 
with eix-sync (instead of emerge --sync) and it shows you a very detailed 
report of what has been updated (or downgraded) and which of these updates 
apply to your system.

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] Booting from Install cd

2006-10-31 Thread Pawel Kraszewski
Dnia wtorek, 31 października 2006 11:14, Arnau Bria napisał:

  I am sorry for such a newbie question but I really wane start
  learning more about linux and use gentoo on my desktop computer.
 
  Now I've burned both pcc and pcc64 to two cd's but when rebooting it
  just boots back into my old system which were Mandriva 2006 with Lilo

 Try ia64.

Yes, if those 2 CPUs Kyle mentioned are Itanium processors - I doubt. I guess 
these are EM64T processors in which case the correct setting is somewhat 
misleading AMD64 . 

In case of EM64T, the system setting can be built upon this setting 
(in /etc/make.conf):

CHOST=x86_64-pc-linux-gnu
CFLAGS=-march=nocona -O2 -pipe
CXXFLAGS=${CFLAGS}

The NOCONA setting is crucial, as Intel is slightly different from AMD.

Also, look at your /proc/cpuinfo , flags section. Than set appropriate USE 
flags according to this table:

CPU flag   | set this
 present   | USE flag
---+-
mmx| mmx
sse| sse
sse2   | sse2
pni| sse3 *
mmxext | mmxext
3dnowext **| 3dnowext
3dnow**| 3dnow

*  No ebuild seems to use sse3 flag (yet)
** Well, 3dnow is for AMD/AMD64, put here just for reference

See also at http://gentoo-wiki.com/Safe_Cflags .


-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] How to detect when memory-card inserted into USB card-reader?

2006-10-14 Thread Pawel Kraszewski
Dnia niedziela, 15 października 2006 07:08, Walter Dnes napisał:

   If I stick the SD memory-card from my camera into my USB all-in-one
 memory card-reader *BEFORE PLUGGING THE CARD-READER INTO THE USB PORT*,
 it's recognized as /dev/sdb and mount works as expected.

   If I stick the SD memory-card from my camera into my USB all-in-one
 memory card-reader *AFTER  PLUGGING THE CARD-READER INTO THE USB PORT*,
 no such luck.  If I fdisk /dev/sdb (which requires root) then it wakes
 up something somewhere, the card is recognized as /dev/sdb and mount
 works as expected.

   Is it possible to get the system to automatically recognize when a
 card is inserted into the reader?

Look at:

sys-apps/ivman
  Homepage:http://ivman.sf.net
  Description: Daemon to mount/unmount devices, based on info from HAL


-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] LDAP with no privileged login

2006-10-12 Thread Pawel Kraszewski
Dnia czwartek, 12 października 2006 17:50, Leandro Melo de Sales napisał:

   I'm configured a LDAP server to be used as a users database. Now, I
 want to setup linux box clients to auth against LDAP server. I
 installed ldap-pam and ldap-nss. In /etc/ldap.conf file I have to
 inform rootdn password. What is the best way to do this since the
 configuration file has to be readable to all. I think that use
 privileged login in this situation (even if I use /etc/ldap.secret
 file) is dangerous. So, should I created a LDAP user just to be used
 as a rootdn login? how can I create a nonprivileged login?

1. You create user in LDAP tree _outside_ ou=people tree
2. Set password for it and disable shell login (just in case)
3. Tell ldap-nss to use this user as binddn= with pass bindpw=
4. Allow owner of the record (logged-on user) to change his/her password

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] Can smbmount handle long passwords?

2006-10-12 Thread Pawel Kraszewski
Dnia czwartek, 12 października 2006 21:13, Maxim Eremeev napisał:

 Due to a little bit of paranoia I have found an interesting, though rather
 annoying, bug in smbmount. If a samba user's password is longer than 23
 chars, smbmount just cannot deal with it, producing the following error:

Well, I might be wrong, but I think Windoze has a limit of 14 characters in 
passsword (two 7 character pieces to be exact). I didn't try, but it seems 
that pass might be truncated at 14th character... So try logging in with 14 
first characters of your password (or maybe 14 last - who knows the paths of 
Bill)

HTH 

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] Dumb question

2006-10-11 Thread Pawel Kraszewski
Dnia środa, 11 października 2006 06:21, Anthony E. Caudel napisał:
 I have been using Gentoo for more than 2 years now and have always
 wondered (but never asked - That's the dumb part) how Gentoo manages
 to update a package that happens to be running at the time.

 Given that the old version (the one running) is deleted, how does it
 manage to keep standing if you just cut its legs off?

 I've never seen this discussed anywhere which probably means everyone
 else already knows and are probably thinking to themselves, Dumb
 question.

Observe CAREFULLY sequence of operations during emerge. It doesn't remove old 
package and install new ones. It installs the new one over the old and then 
removes unnecessary remains.

It may overwrite file in use due to the way Unices handle file management. On 
Windows you can't delete open file. On Unix you can, and process keeping file 
open won't usually notice that. Moreover, as long as the file is open, its 
data isn't removed from disk. Once the process closes it, it is physically 
removed - not sooner.

So after overwriting file (library, application) currently running 
applications (having it open) will still have access to old version and each 
newly run application will use the new one.

Which in turn means - yes, you need to 'power cycle' application to use new 
libraries or new version of executable.

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] how to execute some scripts after an emerge

2006-10-07 Thread Pawel Kraszewski
Dnia sobota, 7 października 2006 03:16, Robert Welz napisał:
 Hello!

 Are there hooks in portage with which I can execute some scripts after
 an emerge -u world? I need to check my libraries in the chroot jail :) I
 build for boinc today against their original counterparts in the file
 system. This would be nicer than having a cronjob looking after them at
 fixed intervals.

Well, that would be 

emerge -your -parameters  /your/script

Script would be called on successful emerge.

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] recompiing kernel quesiton

2006-09-24 Thread Pawel Kraszewski
Dnia niedziela, 24 września 2006 01:46, Stephen Liu napisał:

Please, switch off HTML posting as it annoys plenty of users...

Correct sequence for kernel generation/update is:

Go to your new kernel directory and first get your running kernel config (if 
you enabled this in previous kernel):

# zcat /proc/config.gz  .config

Now fix the config (observing which options have NEW at the end and 
consulting online help what do they mean)

# make menuconfig
or
# make xconfig

Now compile the kernel

# make

And install it

# make modules_install
# make install

Afterwards you do nothing (if you have GRUB) or run lilo (guess, if you have 
LILO :)

Take note, that some software doesn't work in monolithic kernel (meaning with 
modules disabled) - especially third-party binary drivers (nvidia, ATI, 
probably ndiswrapper)

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] recompiing kernel quesiton

2006-09-24 Thread Pawel Kraszewski
Dnia niedziela, 24 września 2006 11:51, Stephen Liu napisał:

 I'm suffering poweroff problem, on exiting System halted but not
 poweroff.

First of all - you may try the installation CD of Gentoo - boot it and 
give 'halt -p' at command prompt. If it switches off, that means error in 
your config. If it doesn't, this might be the hardware fault.

Put some light and describe your hardware. Especially - which motherboard 
model, drop your 'lspci' output. Contents of '/var/log/dmesg' might also be 
helpful. The latter might be too big for this mailing list, so don't hesitate 
to drop it gzipped directly to my address. 

By the way - did you inspect your BIOS settings for ACPI/power management 
misconfiguration? 

If you want, I may drop you my kernel configuration (AMD64, Nforce3 based 
mainboard) - due to my work it covers all usable filesystems and most IPv4 
toys. It does switch off without problem - you may use it as a starting point 
for experiments.

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] Recommend an HTML/CSS editor?

2006-09-18 Thread Pawel Kraszewski
Dnia wtorek, 19 września 2006 04:38, Kevin O'Gorman napisał:

 I'm about to write a bunch more, and I'm hoping there's a Linux
 product that works reasonably well with CSS style sheets.  Anybody
 know of one.  Free is good, cheap is acceptable.

Look at:

app-editors/nvu
 Available versions:  0.90-r2 1.0-r2 1.0-r4
 Homepage:http://www.nvu.com/
 Description: A WYSIWYG web editor for linux similiar to
  Dreamweaver

This is a web-editor ripped and evolved from Mozilla Suite

kde-base/quanta
 Available versions:
(3.4)   3.4.3
(3.5)   3.5.2 3.5.3 3.5.4
 Homepage:http://www.kde.org/
 Description: KDE: Quanta Plus Web Development Environment

This is a KDE-standard-compliant web editor

app-editors/bluefish
 Available versions:  1.0 1.0.2 1.0.4 1.0.4-r1 1.0.5
 Homepage:http://bluefish.openoffice.nl/
 Description: A GTK HTML editor for the experienced web designer
   
  or programmer.
This is GTK-standard-compliant web editor

HTH

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] 64-bit system?

2006-09-18 Thread Pawel Kraszewski
Dnia poniedziałek, 18 września 2006 17:49, Richard Fish napisał:

 You'll only notice a speed increase with applications that need to
 caculate very large numbers, like encryption keys and certain
 scientific apps.  Everything else will basically run just as fast in
 32-bit mode as it will in 64-bit.  There are exceptions in certain
 media encoders that don't have hardware optimizations for 64-bit, that
 may actually run faster as 32-bit apps.

Well, the registers are not only twice longer, but there is twice as much of 
them as in 32-bit. And THIS is what optimising compilers are fond of. More 
registers mean less in-memory temporary variables, which in turn means less 
memory accesses. This gives speed improvement. For SMP systems it gives huge 
difference - as the memory is shared between CPUs and they must fight for it.

I have an amd64 system for over a year (or is it 2-yrs?). I had some glitches:

* Need to use binary 32-bit firefox to have flash - still have problems with 
  some fonts not appearing in flash
* Need to use 32-bit java to make 32-bit OpenOffice happy
* Some forensic packages won't compile on 64-bit due to bad coding techniques

But besides that - my AMD64 3000+ just rocks. I had definitely much more 
problems with 64-bit XP, but since getting rid of it (XP not problems) I am 
fully 64-bit positive :D

-- 
 Pawel Kraszewski
 www.kraszewscy.net

-- 
gentoo-user@gentoo.org mailing list