Re: mbox retrieval

2006-07-23 Thread Giorgos Keramidas
On 2006-07-22 10:06, Robert Davison [EMAIL PROTECTED] wrote:
 I've received some email and read it using the simple 'mail'
 command. I use qpopper to pick up the email remotely, but it seems
 becasue I read it on the main mail server then qpopper wont pass it
 through the system.

 I've found the mail in my 'mbox' folder. My question is...is there
 anyway of reinstating this email so that qpopper wil send it back
 through to my mail client ?

Apparently, what has happened is that you used mail(1), but forgot to
set the 'hold' option.  This means that any email messsages you marked
as read (either manually or by reading them) have now been moved from
your default `$MAIL' folder to `$HOME/mbox'.

Now you can use mail(1) to move these back to your `$MAIL' folder
wherever that is.

% [EMAIL PROTECTED]:/home/giorgos$ mail -f mbox
% Mail version 8.1 6/6/93.  Type ? for help.
% mbox: 1 message
%1 [EMAIL PROTECTED] Tue Jul  4 06:17  57/2658  Re: vmem and uma 
(was Re: DTrace for Free
%  s 1 $MAIL 
% /home/giorgos/Mailbox [Appended]
%  x
% [EMAIL PROTECTED]:/home/giorgos$ 

Ranges of messages can be moved to the $MAIL folder with:

s 1-100 $MAIL

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: [OT] gcc: maximum length of an array?

2006-07-23 Thread Giorgos Keramidas
On 2006-07-24 20:49, P.U.Kruppa [EMAIL PROTECTED] wrote:
 Hi,

 sorry for posting an [OT], but usually people on this list know
 everything :-)

 Since I don't know too much about programming I am frequently
 fascinated by simple things like Eratosthenes' sieve.  As you might
 remember, one has to create a boolean array for that. The longer the
 array the more primes can be found.

 With malloc() I can create an array of length 1 (10^8) and the
 first 5761455 primes are calculated in a few seconds.  So of course I
 would like to test length 10^9 but here my program crashes.

If this is about integer values, which are probably 32-bit, you are
hitting the kern.maxdsiz limit of 512 MB.  An array of 100,000,000
32-bit values takes up 4 * 100,000,000 = 400,000,000 (close to 400 MiB
of memory to store).  Anything above 512 MB in size will make the data
size of your program so big that it will overflow the data seg size:

$ ulimit -a
core file size  (blocks, -c) unlimited
data seg size   (kbytes, -d) 524288
...

You can either increase kern.maxdsiz in your `/boot/loader.conf' file,
or redesign the algorithm to work with larger datasets by splitting them
in chunks that you can still process with 512 MB of data :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: im about to sit down an read the entire postfix manuals...

2006-07-22 Thread Giorgos Keramidas
On 2006-07-22 16:20, Jonathan Horne [EMAIL PROTECTED] wrote:
 becuase i want to know if it supports a specific feature or not.  so
 before i do and spend all that time, i just thought i would ask a
 simple question or 2 to this list.

 my problem: i have 5 domains that my sendmail server recieves mail
 for, and im starting to get spammed at [EMAIL PROTECTED] as well as
 [EMAIL PROTECTED] etc etc.  realistically, name1 only needs to receive
 at domain1, and none of the others.  there are many other accounts
 that only need to recieve at other specific domains, and not at any of
 them.

Are you using virtusertable for the domains?  Then you can use something
like this in `/etc/mail/virtusertable':

[EMAIL PROTECTED]   name1
@domain1.com550: User unknown

[EMAIL PROTECTED]   name2
@domain2.com550: User unknown

You don't have to replace your mailserver then :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: im about to sit down an read the entire postfix manuals...

2006-07-22 Thread Giorgos Keramidas
On 2006-07-22 18:04, Jonathan Horne [EMAIL PROTECTED] wrote:
 On Saturday 22 July 2006 17:55, Giorgos Keramidas wrote:
  On 2006-07-22 16:20, Jonathan Horne [EMAIL PROTECTED] wrote:
   my problem: i have 5 domains that my sendmail server recieves mail
   for, and im starting to get spammed at [EMAIL PROTECTED] as well
   as [EMAIL PROTECTED] etc etc.  realistically, name1 only needs to
   receive at domain1, and none of the others.  there are many other
   accounts that only need to recieve at other specific domains, and
   not at any of them.
 
  Are you using virtusertable for the domains?  Then you can use something
  like this in `/etc/mail/virtusertable':
 
  [EMAIL PROTECTED]   name1
  @domain1.com550: User unknown
 
  [EMAIL PROTECTED]   name2
  @domain2.com550: User unknown
 
  You don't have to replace your mailserver then :)
 
 im actually a little proud of myself... just as this mail was comming
 in, i am finishing up my testing/deployment of this exact
 configuration.  this was exactly what im looking for.

Excellent!  :)

 of my 5 domains, i probably have 10 addresses on 1, and then the rest
 have either 1 or 2.  i think for now this configuration is going to be
 exactly what i am looking for, but i wonder what larger organizations
 who use only sendmail, and have this sort of requirment, if this is
 what they do too?

I don't know about large organizations.  We[1] use this scheme in our
mail servers for a moderate amount of domains.  It suits our limited
needs quite fine.

[1] The team of admins of HELLUG, the Hellenic Linux Users' Group.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: User crontab file dosent run...?

2006-07-17 Thread Giorgos Keramidas
On 2006-07-17 10:17, perikillo [EMAIL PROTECTED] wrote:
 Hi people.
 
  Im testing how to run scripts from cron using the crontab program,
 the handbook say tha each user need to have a crontab file if they
 want to run some process with the cron program:
 
 user-x$ crontab -e
 
 SHELL=/bin/sh
 PATH=/etc:/bin:/sbin:/usr/bin:/usr/sbin
 MAILTO=root
 */1 *   *   *   *   user-x /bin/echo Testing

The /etc/crontab file is *NOT* the same as the user crontab files.

It has an extra field, at column 6, which specifies which user this
entry will run as.

In user crontabs, the sixth field is the command-name, as below:

| $ crontab -l
| PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/games:/usr/local/bin:/home/giorgos/bin
| 
| # Email me calendar entries at 00:00 every day
| @daily  /usr/bin/calendar
| 
| # Save backup copies of my Mercurial repositories in /g/repos
| 0,10,20,30,40,50 * * * */home/giorgos/cron.d/repos-gker
| 
| # Save backup copies of my Mercurial repositories in /g/repos
| #3,13,23,33,43,53 * * * *   /home/giorgos/cron.d/repos-bmi
| 
| # Rotate all log files under `/home/giorgos/log', according to the
| # options specified in the `/home/giorgos/log/newsyslog.conf' file.
| #8,18,28,38,48,58 * * * *   /home/giorgos/cron.d/logrotate
| $

So, your user crontab entry tries to run a command called `user-x',
which does not exist of course...

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: SMP Performance (Was: Re: Are hardware vendors starting to bail ... )

2006-07-16 Thread Giorgos Keramidas
On 2006-07-16 11:45, User Freebsd [EMAIL PROTECTED] wrote:
 The problem, as I see it, is that until the OS gets used in real life
 production environments, some of the more obscure bugs don't get
 found ... on a simple production server, not doing much, I doubt
 anyone would ever see the file system deadlocks ... but, there are
 several of us that are running it in production with heavy loads that
 do ... but it takes a good load on the machine to trigger it, and I
 doubt any of the developers have that to work with, and/or can easily
 simulate the 'randomness' of a production environment ...

Well said!

Very much to the point, with reasonable, realistic arguments,
as always, Marc :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Are hardware vendors starting to bail on FreeBSD ... ?

2006-07-13 Thread Giorgos Keramidas
On 2006-07-13 11:31, Danial Thom [EMAIL PROTECTED] wrote:
 Here's the deal, Chad. On this list, all the college-kid sysadmins
 tell me how great FreeBSD is, but on the freebsd-performance list,
 none of the developers refute my findings. If that doesn't tell you
 something, then you really don't have the capacity to comment on this
 or any other subject.

That's _not_ the impression I get from threads like:

  http://lists.freebsd.org/pipermail/freebsd-performance/2006-June/002043.html
  http://lists.freebsd.org/pipermail/freebsd-performance/2006-June/002074.html

These are, also, the only two threads in which your name appears since
January 2004, so before throwing around accusations about the FreeBSD
developers not answering your alleged performance findings -- of which
there is absolutely NO evidence in the freebsd-performance list archives
-- please consider that your false comments in a mailing list with a
wide distribution, like freebsd-questions, are NOT doing any good to
FreeBSD and have a big probability of being characterized as troll
stuff.

Having this in mind, and bearing in mind the many contributions of Chad
to this list, which are of higher quality and in general contain text of
a far greater signal/noise ratio, I'm not sure it is so fair of you to
call people of this list college-kid sysadmins or to comment on Chad's
capacity to comment on any subject.

Nice troll, though...

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: been buggin' me for a while now (console resolution)

2006-07-11 Thread Giorgos Keramidas
On 2006-07-10 23:32, Peter [EMAIL PROTECTED] wrote:
--- Stubborn [EMAIL PROTECTED] wrote:
 You need to recompile your kernel with below
 options VESA

 Allright, did that.

 You need to include these in your rc.conf
 allscreens_flags=132x25

 I'm trying manually first and it's a no go.  This is the output of
 'vidcontrol -i mode':

   0 (0x000) 0x0001 T 40x25   8x8   0xb8000 32k 32k 0x 32k
   1 (0x001) 0x0001 T 40x25   8x8   0xb8000 32k 32k 0x 32k
   2 (0x002) 0x0001 T 80x25   8x8   0xb8000 32k 32k 0x 32k
   3 (0x003) 0x0001 T 80x25   8x8   0xb8000 32k 32k 0x 32k
   4 (0x004) 0x0003 G 320x200x2 1 8x8   0xb8000 32k 32k 0x 32k
   5 (0x005) 0x0003 G 320x200x2 1 8x8   0xb8000 32k 32k 0x 32k
   6 (0x006) 0x0003 G 640x200x1 1 8x8   0xb8000 32k 32k

The 132x25 mode doesn't work for all video adapters, AFAIK.

The best I have been able to use almost everywhere is 80x30.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: been buggin' me for a while now (console resolution)

2006-07-11 Thread Giorgos Keramidas
On 2006-07-11 12:04, Stubborn [EMAIL PROTECTED] wrote:
 [snip 312 lines of quoted material]

 Peter,

 have you tried rebooting your box and put allscreens_flags=132x25 in
 your rc.conf?

That won't work if his adapter doesn't support 132x25 either.

Also, please *trim* the quoted material.  Having to skim again and again
through multi-hundred posts of quoted material to find out that you have
only added about 2 lines of text near the end is silly.

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: been buggin' me for a while now (console resolution)

2006-07-11 Thread Giorgos Keramidas
On 2006-07-11 08:43, Peter [EMAIL PROTECTED] wrote:
--- Giorgos Keramidas [EMAIL PROTECTED] wrote:
On 2006-07-10 23:32, Peter [EMAIL PROTECTED] wrote:
--- Stubborn [EMAIL PROTECTED] wrote:
 You need to recompile your kernel with below
 options VESA

 Allright, did that.

 You need to include these in your rc.conf
 allscreens_flags=132x25

 I'm trying manually first and it's a no go.  This is the output of
 'vidcontrol -i mode':

 [snip]

 34 (0x022) 0x0001 T 80x60   8x8   0xb8000 32k 32k 0x 32k

 The 132x25 mode doesn't work for all video adapters, AFAIK.

 The best I have been able to use almost everywhere is 80x30.

 I can manually get 80x60 with 'vidcontrol 80x60' and this is good
 enough for me.  How do I automate this at bootup?

By setting your preferred mode in `/etc/rc.conf':

allscreens_flags=80x30

Note that for non-default modes, you also have to set up a font in your
`rc.conf' file, otherwise vidcontrol will refuse to change the console
mode at bootup, so a more complete example would be:

font8x8=iso-8x8.fnt
allscreens_flags=80x60

After saving these in your `/etc/rc.conf' file you don't have to reboot
for them to take effect, something like the following should work too:

hostname# /bin/sh
# vidcontrol -f 8x8 iso-8x8.fnt
# for dev in /dev/ttyv* ; do vidcontrol 80x60  $dev ; done

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


aterm -e screen does not source .bashrc (was: Re: been buggin' me for a while now (console resolution))

2006-07-11 Thread Giorgos Keramidas
On 2006-07-11 09:09, Peter [EMAIL PROTECTED] wrote:
 I have the following in my .xinitrc file:
 
 aterm -e screen 
 
 What is happening is that neither /etc/profile nor ~/.profile are
 being read.  How can I get either of them to be sourced?

By default, xterm, rxvt, aterm and various other terminal emulators
start non-login shells.  This means that .profile is not sourced by the
shell spawned by the terminal.  You can enable a `login shell' inside
one of these terminal emulators with the -ls option:

aterm -ls -e screen 
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: aterm -e screen does not source .bashrc (was: Re: been buggin' me for a while now (console resolution))

2006-07-11 Thread Giorgos Keramidas
On 2006-07-11 09:40, Peter [EMAIL PROTECTED] wrote:
--- Giorgos Keramidas [EMAIL PROTECTED] wrote:
On 2006-07-11 09:09, Peter [EMAIL PROTECTED] wrote:
 I have the following in my .xinitrc file:
 
 aterm -e screen 
 
 What is happening is that neither /etc/profile nor ~/.profile are
 being read.  How can I get either of them to be sourced?
 
 By default, xterm, rxvt, aterm and various other terminal emulators
 start non-login shells.  This means that .profile is not sourced by
 the
 shell spawned by the terminal.  You can enable a `login shell' inside
 one of these terminal emulators with the -ls option:
 
  aterm -ls -e screen 
 
 
 I added this option but I still do not get my ~/.profile sourced (no
 aliases).  Going '. ~/.profile' gives me my aliases.  How does aterm
 know what file to look for?

aterm doesn't care about .profile or other files.  It starts a shell,
based on the $SHELL environment variable and your login shell from
`/etc/passwd'.

What shell are you using?

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: aterm -e screen does not source .bashrc

2006-07-11 Thread Giorgos Keramidas
On 2006-07-11 15:33, Alex Zbyslaw [EMAIL PROTECTED] wrote:
Giorgos Keramidas wrote:
 By default, xterm, rxvt, aterm and various other terminal emulators
 start non-login shells.  This means that .profile is not sourced by the
 shell spawned by the terminal.  You can enable a `login shell' inside
 one of these terminal emulators with the -ls option:

  aterm -ls -e screen 

 But a better option, IMHO,  is to correctly separate the functionality in
 your .profile from that in some other (e.g. .shinit) file.  One is for
 only stuff that happens at login, one for stuff that happens regardless.

Yes, of course :-)

 from man sh

 When first starting, the shell inspects argument 0, and if
 it begins with a dash (-), the shell is also considered a
 login shell.  This is normally done automatically by the
 system when the user first logs in.  A login shell first
 reads commands from the files /etc/profile and then
 .profile if they exist.  If the environment variable ENV is
 set on entry to a shell, or is set in the .profile of a
 login shell, the shell then reads commands from the file
 named in ENV.  Therefore, a user should place commands that
 are to be executed only at login time in the .profile file,
 and commands that are executed for every shell inside the
 ENV file.  The user can set the ENV variable to some file
 by placing the following line in the file .profile in the
 home directory, substituting for .shinit the filename
 desired:

 ENV=$HOME/.shinit; export ENV

 IMHO, this one one of the ways that csh was miles ahead of sh as a login
 (as opposed to a scripting) shell.  These days, of course, a modern shell
 like bash has many of the best features of both, and even sh can
 (finally) do command line editing.

Agreed.  My current .bash_profile is basically a minimal wrapper around
.bashrc these days:

% gothmog % cat -n .bash_profile
%  1  # Startup file for login instances of the bash(1) shell.
%  2  # $RCS: giorgos/.bash_profile,v 1.10 2005/07/10 21:10:39 giorgos Exp $
%  3
%  4  # First of all, run a .bashrc file if it exists.
%  5  test -f ~/.bashrc  . ~/.bashrc
%  6
%  7  # The following section should be pretty minimal, if present at all.
%  8  mesg y /dev/null 21
%  9  /usr/bin/true
% gothmog %
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: aterm -e screen does not source .bashrc (was: Re: been buggin' me for a while now (console resolution))

2006-07-11 Thread Giorgos Keramidas
On 2006-07-11 11:18, Peter [EMAIL PROTECTED] wrote:
 I added this option but I still do not get my ~/.profile sourced
 (no aliases).  Going '. ~/.profile' gives me my aliases.  How does
 aterm know what file to look for?

 aterm doesn't care about .profile or other files.  It starts a shell,
 based on the $SHELL environment variable and your login shell from
 `/etc/passwd'.

 What shell are you using?

 $ echo $SHELL
 /usr/local/bin/bash

 $ grep peter /etc/passwd
 peter:*:1002:100:User :/home/peter:/usr/local/bin/bash

 Do I need to set up a different file (.bashrc)?

GNU bash will not read .profile if you also have a .bash_profile file.

What do you see in your HOME directory with:

$ ls -ld .*profile .*rc

In my local setup here, I see something like this:

$ pwd
/home/giorgos
$ ls -ld .bash* .sh* .profile
-rw---  1 giorgos  giorgos  - 30103 Jul 11 18:47 .bash_history
-rw-rw-r--  1 giorgos  giorgos  -   318 Jul 11 17:47 .bash_profile
-rw-rw-r--  1 giorgos  giorgos  -  3742 Jul 11 18:17 .bashrc
-rw-rw-r--  1 giorgos  giorgos  -  1006 Mar 29 07:19 .profile
-rw-rw-r--  1 giorgos  giorgos  -  1433 Nov 18  2004 .shrc
$

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: aterm -e screen does not source .bashrc (was: Re: been buggin' me for a while now (console resolution))

2006-07-11 Thread Giorgos Keramidas
On 2006-07-11 12:05, Peter [EMAIL PROTECTED] wrote:
--- Giorgos Keramidas [EMAIL PROTECTED] wrote:
 What do you see in your HOME directory with:

  $ ls -ld .*profile .*rc

 In my local setup here, I see something like this:

 $ pwd
 /home/giorgos
 $ ls -ld .bash* .sh* .profile
 -rw---  1 giorgos  giorgos  - 30103 Jul 11 18:47 .bash_history
 -rw-rw-r--  1 giorgos  giorgos  -   318 Jul 11 17:47 .bash_profile
 -rw-rw-r--  1 giorgos  giorgos  -  3742 Jul 11 18:17 .bashrc
 -rw-rw-r--  1 giorgos  giorgos  -  1006 Mar 29 07:19 .profile
 -rw-rw-r--  1 giorgos  giorgos  -  1433 Nov 18  2004 .shrc


 $ ls -ld .*profile .*rc
 -rw-rw  1 peter  users   767B Jul 29  2005 .cshrc
 -rw---  1 peter  users26B May  2 11:08 .dmrc
 -rw-rw  1 peter  users   331B Jul 29  2005 .mailrc
 -rw-rw  1 peter  users31B Jun 28 21:33 .mcoprc
 -rw-rw  1 peter  users   1.6K Jul  4 15:31 .profile
 -rw-r--r--  1 peter  users   616B Jun 19 22:10 .screenrc
 -rw-rw  1 peter  users   975B Jul 29  2005 .shrc
 -rw-rw  1 peter  users   402B Jul 11 09:29 .xinitrc

Damn :(

Sorry for the bogus request.  I meant:

$ ls -ld .bash* .sh* .profile

and I correctly used this in my own check, but then forgot to fix the
one I asked you for.

What you sent doesn't show any .bash* files and I still don't know if
you have both a .bash_profile and a .profile file.

Can you please also send the output of:

$ ls -ld .bash* .sh* .profile

Sorry for the confusion...

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: aterm -e screen does not source .bashrc (was: Re: been buggin' me for a while now (console resolution))

2006-07-11 Thread Giorgos Keramidas
On 2006-07-11 12:39, Peter [EMAIL PROTECTED] wrote:
 --- Giorgos Keramidas [EMAIL PROTECTED] wrote:
  Can you please also send the output of:
  
  $ ls -ld .bash* .sh* .profile
 
 $ ls -ld .bash* .sh* .profile
 -rw-rw  1 peter  users   7.7K Jul 11 09:31 .bash_history
 -rw-rw  1 peter  users   1.6K Jul  4 15:31 .profile
 -rw-rw  1 peter  users   975B Jul 29  2005 .shrc

Strange, there is no .bash_profile but you still see .profile is unused?

I just tested here, with the CVS mirroring account I have at this
workstation, by:

* moving .bash_profile and .bashrc away

* adding an 'echo' message in its .profile file:

  echo .profile done

and when I su(1) to this account, the .profile is used by bash!

gothmog# su - ncvs
.profile done
[EMAIL PROTECTED] ~]$ echo $SHELL
/usr/local/bin/bash
[EMAIL PROTECTED] ~]$

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: aterm -e screen does not source .bashrc (was: Re: been buggin' me for a while now (console resolution))

2006-07-11 Thread Giorgos Keramidas
On 2006-07-11 14:11, Peter [EMAIL PROTECTED] wrote:
--- Giorgos Keramidas [EMAIL PROTECTED] wrote:
 I just tested here, with the CVS mirroring account I have at this
 workstation, by:

 [snip]

 and when I su(1) to this account, the .profile is used by bash!

 There is no question that .profile is sourced when I log in.  It is
 sourced.  It is only not sourced when I invoke aterm from within
 .xnitrc:

 aterm -ls -e screen 

Aha.  I think I'm getting somewhere.

If I run xterm with the -e option, regardless of -ls being present or
not, the shell used to spawn the -e command is *NOT* a login shell.

This way, when I run:

xterm   = not login shell

xterm -ls   = login shell

xterm -e /bin/sh= not login shell

xterm -ls -e /bin/sh= not login shell either

So it's not the -ls option that is causing your aterm windows to be
non-login shells, but it looks like it is the -e option that does this.


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: shared library loader configuration

2006-07-10 Thread Giorgos Keramidas
On 2006-07-10 15:07, [EMAIL PROTECTED]@mgedv.net [EMAIL PROTECTED] wrote:
 Giorgos Keramidas wrote:
  [lengthy example about compiling with -L and -R options]

 1st of all, thx for the efforts to clarify things.

No problem :)

 but now, i use -L and -R, this works fine (until now) and
 maybe it's not necessary anymore, to workaround ldconfig.

Thanks for taking the time to post a followup that it all works now.


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Boot Menu

2006-07-09 Thread Giorgos Keramidas
On 2006-07-10 10:53, RdBSD [EMAIL PROTECTED] wrote:
 Dear All,

 How can i change default menuitem in boot menu to number 3 or safe
 mode. so it will boot the default to number 3 in menu ?

That's usually a slightly bad idea.  Why do you want to do this?

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: shared library loader configuration

2006-07-07 Thread Giorgos Keramidas
On 2006-07-07 13:22, [EMAIL PROTECTED]@mgedv.net [EMAIL PROTECTED] wrote:

 hi,

 can someone give me please a SIMPLE and CLEAR answer, what i exactly
 have to do to achieve the following:

 i have (for example) installed a new compiled version of libz.a/.so in
 /usr/local.

 i want program (during runtime AND during compilation) to compile and
 run against the NEW and non-system libs.

In short, just don't.

The system programs have been tested, developed and debugged with the
*SYSTEM* version of the libraries.  Blindly replacing these libraries
with others is something you should do only with extreme care.

 what has to be set/changed, to have this setting as soon as the OS
 starts?

LD_LIBRARY_PATH is probably what you mean here.

 i tried running ldconfig, i was playing around with some ld-so.conf
 files, everything failed. the compilation does not even find the new
 libraries, and if i use ldd to check what path the lib would use
 it's always /lib or /usr/lib instead of /usr/local/lib.

All the compilers that I have to use for every day work and for my own
stuff have options that can hardcode a 'runtime library path' in the ELF
binary.

What did you try to compile?

What do you mean by writing ``the compilation does not even find the new
libraries''?

 please don't tell me things about RTFM or weblinks

This is also a good way of learning new stuff though :)

 i just need ~3 simple lines of what the hell to do that i get a
 persisting setting for compilations and runtimes

How do you know it is ``3 simple lines''?

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: shared library loader configuration

2006-07-07 Thread Giorgos Keramidas
On 2006-07-07 14:22, [EMAIL PROTECTED]@mgedv.net [EMAIL PROTECTED] wrote:
 dunno, if it's a misunderstanding, but my only question how to tell
 the system where to load libraries and in which order to prefer paths
 seems to be still open.

 anyway, thx for the reply ;-)

 ps: i already RdTFM ;-)

You don't.  Unless you modify the /etc/rc.d/ldconfig script manually,
/lib and /usr/lib will always be the first to search.

I'm still not convinced that telling the system where to load libraries
from is the solution to you problem, but I don't know what the problem
is.  You have to describe first *WHAT* the real problem is and *WHY* you
think modifying the library path is a solution.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: shared library loader configuration

2006-07-07 Thread Giorgos Keramidas
On 2006-07-07 14:58, [EMAIL PROTECTED]@mgedv.net [EMAIL PROTECTED] wrote:
Giorgos Keramidas wrote:
On 2006-07-07 14:22, [EMAIL PROTECTED]@mgedv.net [EMAIL PROTECTED] wrote:
 dunno, if it's a misunderstanding, but my only question how to tell
 the system where to load libraries and in which order to prefer
 paths seems to be still open.

 anyway, thx for the reply ;-)

 ps: i already RdTFM ;-)

 You don't.  Unless you modify the /etc/rc.d/ldconfig script manually,
 /lib and /usr/lib will always be the first to search.

 I'm still not convinced that telling the system where to load
 libraries from is the solution to you problem, but I don't know what
 the problem is.  You have to describe first *WHAT* the real problem
 is and *WHY* you think modifying the library path is a solution.

 i found the ldconfig rc-script but i thought there might be a
 cleaner way of telling the system where the shared libraries are to
 be found.

 any way to tell the system: take /usr/local/lib first w.o.  changing
 the ldconfig rc-scripts or developing own startup scripts that achieve
 that?  no way of changing some default configuration file that is
 avail. for that purpose?

No.  For a very good reason too.  If you change the default loader path
to use /usr/local/lib first then *ALL* the programs are affected.  Even
those that are part of the base system.  This is, in general, a very bad
idea as the base-system programs may depend on particular versions of
the libraries to work correctly and those libraries are in /lib:/usr/lib.

 some additional thoughts (a little bit of phil.):

 i wonder, that anybody scripts such hardcoded stuff into a script
 because the environment /etc/ld*conf* exists, and at least for a clear
 and proper way for the admin to define what to load from where it
 should be possible, to override a default configuration via the
 config-files, and not with modifications to rc-scripts which are gone
 by default after each upgrade.

There's a reason why /lib:/usr/lib take precedence over /usr/local.

Don't change that, or be prepared to debug all the potential bugs that
may start appearing.

 to satisfy your couriosity :-)

This description is much better.

 i'd like to compile openssl 0.9.8 and a newer zlib for testing some
 software that does crypto  compression using these libs.  and i
 wanted to keep the servers as clean as possible from changing
 rc-scripts, etc... to ensure we're able to transfer the outcoming
 piece of program to other boxes w'out much effort.  i know it's inside
 the ports but the problem is, we'd like to tes some sort of code
 that's not enabled by default in the ports.

You can always install your own version of openssl and zlib and use an
explicit -R option to tell the linker where to find libraries.  There
are two steps involved in linking and distributing an executable:

* Build-time linking, where the compiler/linker has to be explicitly
  pointed at teh right place with -L/foo/lib paths.

* Runtime linking, where the runtime linker-loader has to lookup and
  locate the library.

You can affect the first one with explicit -L/foo/lib options.  You can
also hardcode one or more paths to the binary -- solving the second
problem too -- if you use -R/distrib/lib options while building.

Your problems are only a matter of using the proper build options.

See for example the ldd output near the end of the following log:

# [EMAIL PROTECTED]:/home/giorgos/tmp/foo# make cleandir
# === lib (cleandir)
# === lib/libz (cleandir)
# rm -f a.out foo.o foo.o.tmp
# rm -f foo.po  foo.po.tmp
# rm -f foo.So foo.so foo.So.tmp
# rm -f libz.so
# rm -f libz.so.* libz.so
# rm -f libz.a libz_p.a libz.so.1
# rm -f .depend GPATH GRTAGS GSYMS GTAGS
# === bin (cleandir)
# === bin/foo (cleandir)
# rm -f foo foo.o
# rm -f .depend GPATH GRTAGS GSYMS GTAGS
# [EMAIL PROTECTED]:/home/giorgos/tmp/foo# make cleandir
# === lib (cleandir)
# === lib/libz (cleandir)
# rm -f a.out foo.o foo.o.tmp
# rm -f foo.po  foo.po.tmp
# rm -f foo.So foo.so foo.So.tmp
# rm -f libz.so
# rm -f libz.so.* libz.so
# rm -f libz.a libz_p.a libz.so.1
# rm -f .depend GPATH GRTAGS GSYMS GTAGS
# === bin (cleandir)
# === bin/foo (cleandir)
# rm -f foo foo.o
# rm -f .depend GPATH GRTAGS GSYMS GTAGS
# [EMAIL PROTECTED]:/home/giorgos/tmp/foo# make obj
# === lib (obj)
# === lib/libz (obj)
# /home/giorgos/tmp/foo/obj/home/giorgos/tmp/foo/lib/libz created for 
/home/giorgos/tmp/foo/lib/libz
# === bin (obj)
# === bin/foo (obj)
# /home/giorgos/tmp/foo/obj/home/giorgos/tmp/foo/bin/foo created for 
/home/giorgos/tmp/foo/bin/foo
# [EMAIL PROTECTED]:/home/giorgos/tmp/foo# make
# === lib (all)
# === lib/libz (all)
# cc -O2 -fno-strict-aliasing -pipe -I/home/giorgos/tmp/foo/lib/libz -g 
-Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -c 
/home/giorgos/tmp/foo/lib/libz/foo.c
# building static z library
# ranlib libz.a
# cc -pg -O2 -fno-strict-aliasing -pipe -I/home/giorgos/tmp/foo/lib/libz -g 
-Wsystem-headers -Werror -Wall -Wno

Re: newfs_msdos - is their an equivalent app with GUI ?

2006-07-06 Thread Giorgos Keramidas
On 2006-07-06 16:46, Didier Tickell [EMAIL PROTECTED] wrote:
 Hi

 I'm so un-terminal savy - Is there an app with a GUI that does FAT
 formatting on macs, like the newfs_msdos command you made ?

 Thanks for your time
 frustrated person...

The solution to this problem is not, of course, to start slapping GUI
wrappers around newfs_msdos, but to read about newfs_msdos and become
acquainted with its options.

You don't *have* to be ``un-terminal savy'', whatever that means.

Have you tried firing up a terminal, and typing:

% man newfs_msdos

The manpages are a huge wealth of information, and there are so many
tools that have neat command-line options that it would be a terrible
waste to miss them all because you didn't check the manpages :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Help fixing sendmail crassh

2006-07-02 Thread Giorgos Keramidas
On 2006-07-02 11:32, Andreas Wider?e Andersen [EMAIL PROTECTED] wrote:
 Hi,
 Sendmail exits about every 30 minutes. I suspect it has to do with some
 mailqueues running, but I don't know how to stop or fix it.

 Running FreeBSD 4.11 p19
 Sendmail 8.13.1

 from /var/log/messages

 Jul  1 20:41:02 malibu /kernel: pid 50923 (sendmail), uid 0: exited on signal 
 11
 Jul  1 21:08:59 malibu /kernel: pid 51058 (sendmail), uid 0: exited on signal 
 11
 Jul  1 21:39:00 malibu /kernel: pid 51252 (sendmail), uid 0: exited on signal 
 11
 Jul  1 22:07:39 malibu /kernel: pid 51374 (sendmail), uid 0: exited on signal 
 11

Are other programs crashing with signal 11 too?  This may be a hardware
problem.  I've been running Sendmail on FreeBSD for ages without any
sign of signal 11:

# cd /var/log
# ( bzcat $( ls -d1 messages*bz2 | sort -r) ; cat messages ) | grep 
'sendmail.*signal'
#

 I was hoping someone could give me a hand here so I can get this issue
 resolved.

* What local configuration changes have you made to the standard
  freebsd.mc and freebsd.submit.mc files?

* Have you checked your memory for errors (see the sysutils/memtest and
  the sysutils/memtest86 ports).

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: multiple links with single ln command

2006-06-28 Thread Giorgos Keramidas
On 2006-06-27 14:14, sara lidgey [EMAIL PROTECTED] wrote:
 Hi All,

 I've read the man page for ln but can't find a way to do this.  I want
 to create multiple links to a single directory with one command.
 Consider the following example.  I have a directory structure like
 this:

 test/a/
 test/b/
 test/c/

 I want to create a symbolic link called clink in test/a/ and test/b/
 which points to test/c/

 The only way I know to do this is with two commands:
 ln -s test/c test/a/clink
 ln -s test/c test/b/clink

 Can it be done with a single command?

I don't think so.  The closest you can come to ``a single command''
would be a loop:

$ for dirname in a b ; do ln -s test/c test/$dirname/clink ; done

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Simple DNS For Private LAN

2006-06-28 Thread Giorgos Keramidas
On 2006-06-23 14:26, Drew Tomlinson [EMAIL PROTECTED] wrote:
 If you use NAT, then I can guide you through setting up a local
 ``master zone'' that is only visible inside your home network, and a
 ``slave zone'' that pulls stuff from ZoneEdit for the
 ``mykitchentable.net'' domain.  I already have a similar setup at
 home, to let my internal systems (workstation, laptop) see each other
 with internal names and still use my ISP's name servers for
 everything else.

 If you don't use NAT, things are going to be much easier, since you
 only have to set up the names at ZoneEdit and pull the master zone
 from there.

 Thank you for your reply.

You're welcome of course :-)

 I use NAT for my servers that are visible from the outside so I set
 ZoneEdit to return the same address for all servers at
 mykitchentable.net which is currently 67.137.238.101.

Excellent!  This is exactly what I was hoping the setup would be.

 Thus www.mykitchentable.net, drew.mykitchentable.net,
 mykitchentable.net, and whatever else. all return 67.137.238.101.
 Based up this, it seems that I should leave ZoneEdit alone and set up
 a local master zone visible only to my private LAN as you describe
 above.  Being a slave and pulling from ZoneEdit wouldn't have any
 benefit as the public address won't equal the private address.

Quite right.

 So assuming I understand correctly, yes, please guide me in setting up
 a local master zone.

Assuming that your local home network uses addresses in the
192.168.0.0/16 range, you have to set up a local name server which will
recognize and reply for the following zones:

drew. # *.drew are local home network names
192.168.0.* # reverse IP address - name for home hosts
127.0.0.*   # localhost zone (optional)

Optionally, you can set up a 'slave' zone for the `mykitchentable.net'
hostnames, but this is not obligatory.

To set up the local nameserver for the local zones mentioned above, you
will need to modify (or create) at least the following files:

/etc/namedb/named.conf
/etc/namedb/master/drew
/etc/namedb/master/drew.rev
/etc/namedb/master/localhost.rev
/etc/namedb/master/localhost-v6.rev
/etc/rc.conf

After you finish setting up all these files, you should be able to:

* Resolve hostnames of the form foo.drew to IP addresses of your
  internal home network.

* Resolve IP addresses of your internal home network to hostnames of
  the form foo.drew.

* Resolve `localhost' to your 127.0.0.1 address (and its IPv6
  equivalent).

* Check your new named setup and see that it works as expected

* Troubleshoot your setup, i.e. tweak the logging level of named and
  find out what it logs through syslog

1. Setting up named.conf


The `named.conf' file is the one BIND reads to find out which `zones' to
load (a `zone' is BIND terminology for what you may have heard being
called a `domain').

The FreeBSD source tree contains a sample `named.conf' file at
`/usr/src/etc/namedb/named.conf', which normally gets installed as
`/etc/namedb/named.conf' on your system.  This file is not used, until
you decide to enable the `named' daemon though.

The sample file installed as `/etc/namedb/named.conf' includes several
commented parts that you can use as examples for writing your own
`named.conf' file.

After you have finished writing your own `named.conf' file it should
contain:

* An `options' section, with global options that apply to the way
  your `named' service works.

* Optionally, a `logging' section, with the configuration options
  that define what is logged, where it is logged, etc.

* A `root' zone entry, which points to the root DNS servers.  An up
  to date list is distributed with the FreeBSD source tree, and can
  be found at `/usr/src/etc/namedb/named.root'.

* Optionally, a `localhost' zone entry (for resolving 127.0.0.1 to a
  hostname of your choise).

* Optionally, a `localhost-v6' zone entry (for resolving the IPv6
  equivalent of 127.0.0.1 to a hostname of your choise).

* A zone entry for your internal, home network.

1.1. Global `options' for `named.conf'
==

The `options' section of your `named.conf' file defines stuff that tunes
global parameters of the `named' service.  After removing the stuff that
is commented out or an example, the `options' section of the default
`named.conf' file looks like this:

options {
directory   /etc/namedb;
pid-file/var/run/named/pid;
dump-file   /var/dump/named_dump.db;
statistics-file /var/stats/named.stats;
listen-on   { 127.0.0.1; };
};

Most of these defaults should work just fine for a standalone `named'
server, but you will have to tweak a bit the `listen-on' option to make
it work in an internal, home network.  The default list of addresses
that your `named' 

Re: Simple DNS For Private LAN

2006-06-28 Thread Giorgos Keramidas
On 2006-06-28 10:10, Drew Tomlinson [EMAIL PROTECTED] wrote:
On 6/28/2006 7:43 AM Giorgos Keramidas wrote:
 So assuming I understand correctly, yes, please guide me in setting
 up a local master zone.

 Assuming that your local home network uses addresses in the
 192.168.0.0/16 range, you have to set up a local name server which
 will recognize and reply for the following zones:

 drew.  # *.drew are local home network names
 192.168.0.*  # reverse IP address - name for home hosts
 127.0.0.*# localhost zone (optional)

 I use virtual servers with Apache.   To access those from the inside,
 I have to use the same URL as is used on the outside.  So from the
 Internet, I need drew.mykitchentable.net to resolve to my public IP
 but on the inside, I need it to resolve to 192.168.0.x.  Thus it seems
 to me that the .drew zone won't work for my setup.  Or am I missing
 something?

It will probably work, as long as the internal machines have an internal
nameserver as the first `nameserver' entry of their `resolv.conf' file.

If you are planning to use the same domain name for both the internal
and externally visible IP addresses, it's not a very good idea though.

Overloading a domain with inside addresses means that when you are
`inside' the local network, you can only see the internal IP addresses :(

 Can I set up my server to be authoritative for .mykitchentable.net
 instead of .drew but only be visible from the inside?

Yes.  But then you will only be able to see internal IP addresses when
you ask for `whatever.mykitchentable.net'.  The external webserver with
the same name will be masked by the internal name server.

 Obviously if it responded to queries from the Internet, I'd really
 have a mess.  What do you recommend?

I generally go for locally visible internal domain names, to avoid the
masking problems mentioned above.  As long as your internal DNS server
blocks queries from everyone except the internal network (i.e. using the
`allow-query' option in either the global options { ... } section or
for the internal zone entry in `named.conf'), this should work.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Cant buildworld

2006-06-25 Thread Giorgos Keramidas
On 2006-06-25 02:35, pid42 [EMAIL PROTECTED] wrote:

 Hi. I have problems building world on a fresh freebsd 6.1. Always ends in:

 == lib/bind (install)
 == lib/bind/bind (install)
 == lib/bind/bind9 (install)
 == lib/bind/dns (install)
 == lib/bind/isc (install)
 == lib/bind/isccc (install)
 == lib/bind/isccfg (install)
 == lib/bind/lwres (install)
 sh /usr/src/tools/install.sh -C -o root -g wheel -m 444   liblwres.a
 /usr/obj/usr/src/tmp/usr/lib
 sh /usr/src/tools/install.s -C -o root -g wheel -m 444
 /usr/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/include/lwres/context.h
 /usr/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/include/lwres/int.h
 /usr/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/include/lwres/ipv6.h
 /usr/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/include/lwres/lang.h
 /usr/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/include/lwres/list.h
 /usr/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/include/lwres/lwbuffer.h
 /usr/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/include/lwres/lwpacket.h
 /usr/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/include/lwres/lwres.h
 /usr/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/include/result.h
 /usr/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/include/lwres/version.h
 /usr/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/unix/include/llwres/net.h
 /usr/src/lib/bind/lwres/lwres/netdb.h
 /usr/src/lib/bind/lwres/lwres/platform.h
 /usr/obj/usr/src/tmp/usr/include/lwres
 sh /usr/src/tools/install.sh -s -o root -g wheel -m 444   liblwres.so.10
 /usr/obj/usr/src/tmp/usr/lib
 ln -fs liblwres.so.10 /usr/obj/usr/src/tmp/usr/lib/liblwres.so
 1 error
 *** Error code 2

You are not using any -j options right?

 Did everything from scratch (formatted, reinstalled from mainmirror). And
 went straight for make buildworld, same error. Tried several make configs.

 Any voodoo to fix this one?  Thanks for the read.

No voodoo should be necessary.  We just have to find out what is
different in your local build setup from the usual process :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Simple DNS For Private LAN

2006-06-23 Thread Giorgos Keramidas
On 2006-06-23 08:21, Drew Tomlinson [EMAIL PROTECTED] wrote:
 I'm having a hard time understanding what I need to do.  I have
 a small home network that uses a 3Com DSL modem/router as the
 last hop to the Internet.  Currently, the DSL modem/router to
 provides DNS for both my home network and the Internet.
 Basically I have a few static entries for machines on my home
 network and then the DSL modem/router queries my ISPs name
 servers for everything else.

 When I registered my domain, I used ZoneEdit as my name
 servers.  'whois mykitchentable.net' gives this output:

 domain: mykitchentable.net
 owner-name: Drew Tomlinson
 nserver:ns3.zoneedit.com 209.61.140.1
 nserver:ns4.zoneedit.com 216.98.150.236

Are machines from your `internal' network visible outside?  If
not, you can set up a locally-visible fake domain, i.e. `*.drew',
and run a local caching name server.  This name server can be a
master for the ``drew.'' zone (``zones'' is what BIND calls parts
of the Domain Name System) and, at the same time, a slave for the
``mykitchentable.net'' zone.

 Now I'm changing ISPs and the DSL modem/router will be removed.
 I am going to use a FBSD 6.x box to be my router, firewall, and
 DNS server.  I read the handbook regarding DNS but remain
 confused.

The Handbook needs a bit of work around that area :-/

 Should I be a master for mykitchentable.net?

Not necessarily.  You can leave the name-servers of zoneedit as
masters.

 I'm thinking not because ZoneEdit is the master, correct?

Correct :-)

 So should I be a slave?

This would be nice.

 And if I'm a slave, will my DNS get it's updates from ZoneEdit?

This depends on whether ZoneEdit allows ``zone transfers'' from
their master name servers to the one you will set up as a slave.

 Or should I become master for my zone and make ZoneEdit a
 backup DNS?

I'd probably leave ZoneEdit as the master, unless your DSL has a
static IP address.  Even if you *do* have a static IP address,
then it is still a good idea to leave ZoneEdit as the master, as
long as they let you become a slave NS.

 I'm a complete newbie to DNS but know that it's important to
 get it right or lots of stuff gets broken.  Can someone please
 guide me in the right direction?  I don't mind reading if you
 send me a link.  :)

I think the next step should be to check if ZoneEdit allows you
to become a slave NS for your zones.

Then you need to decide if the systems you have behind the
FreeBSD gateway will have publicly-visible addresses or use NAT.

If you use NAT, then I can guide you through setting up a local
``master zone'' that is only visible inside your home network,
and a ``slave zone'' that pulls stuff from ZoneEdit for the
``mykitchentable.net'' domain.  I already have a similar setup at
home, to let my internal systems (workstation, laptop) see each
other with internal names and still use my ISP's name servers for
everything else.

If you don't use NAT, things are going to be much easier, since
you only have to set up the names at ZoneEdit and pull the master
zone from there.

Regards,
Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: problems building 6-stable

2006-06-23 Thread Giorgos Keramidas
On 2006-06-23 13:15, Michael P. Soulier [EMAIL PROTECTED] wrote:
 Hello,

 I'm trying to upgrade to the stable 6.1 release, but on a make buildworld, I'm
 getting this

 /usr/obj/usr/src/sbin/gpt created for /usr/src/sbin/gpt
 === sbin/growfs (obj)
 /usr/obj/usr/src/sbin/growfs created for /usr/src/sbin/growfs
 === sbin/gvinum (obj)
 /usr/obj/usr/src/sbin/gvinum created for /usr/src/sbin/gvinum
 === sbin/ifconfig (obj)
 /usr/obj/usr/src/sbin/ifconfig created for /usr/src/sbin/ifconfig
 === sbin/init (obj)
 /usr/obj/usr/src/sbin/init created for /usr/src/sbin/init
 === sbin/ip6fw (obj)
 /usr/obj/usr/src/sbin/ip6fw created for /usr/src/sbin/ip6fw
 === sbin/ipf (obj)
 === sbin/ipf/libipf (obj)
 /usr/obj/usr/src/sbin/ipf/libipf created for /usr/src/sbin/ipf/libipf
 === sbin/ipf/ipf (obj)
 mkdir: /usr/obj/usr/src/sbin/ipf/ipf: File exists
 *** Error code 1

 Stop in /usr/src/sbin/ipf/ipf.
 *** Error code 1

Remove your `/usr/obj' tree, and then run:

# cd /usr/src/sbin/ipf
# make cleandir
# make cleandir

Restart the build and then, AFAIK, it should work as expected.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Serial programming on FreeBSD 6.0 RELEASE

2006-06-22 Thread Giorgos Keramidas
On 2006-06-22 13:55, Andrew Falanga [EMAIL PROTECTED] wrote:
 On 6/22/06, Derek Ragona [EMAIL PROTECTED] wrote:
 
  Kermit may be manipulating the uart directly.
 
 Unless you are not getting the uart to flush the characters.  I have only
 had that problem with doing low-level direct programing.  Typically not a
 problem with high-level coding where you just open the device and set it
 for
 non-buffered output.
 
 Your problem though may be in the stack overflows.  You may need to
 explicitly compile and link it with a larger stack.  It may be these
 overflows causing the output to never get there.

 I'm not sure I understand what you mean.
 Andy

AFAIK, 'silo overflow' messages are *NOT* about stack overflows.

Andy,

can you please post a complete, compilable but minimal program that
exhibits the behavior you find strange?

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: make buildkernel ERROR ?Why?

2006-06-21 Thread Giorgos Keramidas
On 2006-06-21 13:23, Jordi Pavon [EMAIL PROTECTED] wrote:

   Hi, this is my first time I customize my kernel.

   I'm working with Freebsd 6.0, I made a make buildkernel
   KERNELCONF=ALBABRAIN, and I get this error:
   ...
   cc -c -O -pipe -mcpu=pentiumpro -Wall -Wredundant-decls [...]
   -I/usr/src/sys/contrib/ipfilter -I/usr/src/sys/contrib/dev/ath
   -I/usr/src/sys/contrib/dev/ath/freebsd -I/usr/src/sys/contrib/ngatm
   -D_KERNEL -include opt_global.h -fno-common -finline-limit=15000
   -fno-strict-aliasing  -mno-align-long-strings
   -mpreferred-stack-boundary=2 -ffreestanding -Werror  vers.c
   linking kernel
   *** Error code 1
   Stop in /usr/obj/usr/src/sys/ALBABRAIN.
   *** Error code 1
   Stop in /usr/src.
   *** Error code 1
   Stop in /usr/src.
   
   Any help will be apreciated!!

This is not the verbatim, unedited log and it is missing the error
message.  You are not building with -j2 or higher, right?

   This is my customized Kernel ALBABRAIN:
   
   machine  i386
   cpu  I686_CPU
   ident  ALBABRAIN
   options  SCHED_4BSD  #4BSD scheduler
   options  INET   #InterNETworking
[...]

Your mailer or something else that handled this message has changed this
configuration file too much to make a comparison with GENERIC easy.  Can
you attach a text/plain MIME version of the configuration file, please?

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: I need a freebsd 5.3 desktop server; recommendations?

2006-06-19 Thread Giorgos Keramidas
On 2006-06-17 11:29, Dan Bikle [EMAIL PROTECTED] wrote:
 Anish,

 Thanks this is good info.

 I'll be using this server for development of a Ruby on Rails.

 Currently I do development on a Mac.

 My production server is running freeBSD 5.3

You shouldn't be running a production server with 5.3 at all.

The 5.3 release was clearly marked as a developer preview release, so
if you are still running systems with that version, then you should
*first* upgrade your production systems to a more stable FreeBSD
version.

Many important bugs have been fixed on the 5.X branch since the 5.3
version was built, so you should target at the _very_ least the more
stable, debugged  featureful 5.4 or 5.5 releases, or even RELENG_5.

 I want a development environment which is closer to production
 than my Mac is.

Which is a very good point.

This is why you should definitely start by fixing the version of the
production system :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: I need a freebsd 5.3 desktop server; recommendations?

2006-06-19 Thread Giorgos Keramidas
On 2006-06-19 12:33, Erik Trulsson [EMAIL PROTECTED] wrote:
On Mon, Jun 19, 2006 at 01:11:38PM +0300, Giorgos Keramidas wrote:
On 2006-06-17 11:29, Dan Bikle [EMAIL PROTECTED] wrote:
 Anish,

 Thanks this is good info.

 I'll be using this server for development of a Ruby on Rails.

 Currently I do development on a Mac.

 My production server is running freeBSD 5.3

 You shouldn't be running a production server with 5.3 at all.

 The 5.3 release was clearly marked as a developer preview release

 No, it was not.  5.3 was a perfectly ordinary release. It was in fact
 the first 5.x release that was *not* marked as a developer preview.

You're right.  I must have been thinking of 5.2.1.

Sorry for the misinformation :-/

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: I need a freebsd 5.3 desktop server; recommendations?

2006-06-19 Thread Giorgos Keramidas
On 2006-06-19 06:04, Danial Thom [EMAIL PROTECTED] wrote:
--- Giorgos Keramidas [EMAIL PROTECTED] wrote:
On 2006-06-19 12:33, Erik Trulsson [EMAIL PROTECTED] wrote:
 The 5.3 release was clearly marked as a  developer preview
 release

 No, it was not.  5.3 was a perfectly ordinary release. It was in
 fact the first 5.x release that was *not* marked as a developer
 preview.

 You're right.  I must have been thinking of 5.2.1.

 Sorry for the misinformation :-/

 I'd say that a $55. celeron on Freebsd 4.11 would be just as fast as a
 Sempron an 5.3, so why not save some money and get something that
 everyone knows is production ready?

I'm not so sure.  It would take quite a few tests and some _real_
numbers to convince me that such a claim was true :-)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: top

2006-06-14 Thread Giorgos Keramidas
On Wed, 14 Jun 2006 03:40:02 -0500, Nikolas Britton [EMAIL PROTECTED] wrote:
 What do all these things mean, they are from the STATE column in top?:

 bo_wwa
 biowr
 *proce
 getblk
 RUN
 select
 drainv
 *Giant
 nanslp
 pause
 wait
 kserel
 ttyin

They are described in the manpage near this part:

STATE is the current state (one of START, RUN (shown as CPUn
on SMP systems), SLEEP, STOP, ZOMB, WAIT, LOCK or the
event on which the process waits),

The uppercase names are one of the states described in the manpage in
uppercase too.  The lowercase names are the names of sleep-events on
which a process is blocked.  Then there are the names that start with a
'*' character.  These are, AFAIK, names of kernel locks that the process
is currently blocked on.

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Sendmail patch; brings up a questions about buildworld

2006-06-14 Thread Giorgos Keramidas
On Wed, 14 Jun 2006 19:15:14 -0500, Jonathan Horne [EMAIL PROTECTED] wrote:
 with the sendmail patch that came out today, i ask this:

 when in installed this machine as 6.1-RELEASE, i did a buildworld and 
 buildkernel and updated to 6.1-STABLE.

 question: if i choose Patch Solution 1 from 
 http://security.freebsd.org/advisories/FreeBSD-SA-06:17.sendmail.asc, do i 
 need to build a new kernel to go with this, or can i just build the world and 
 be done with it?

You don't need to rebuild everything for Sendmail.  If you still have
your /usr/obj tree around, something like the following should build all
the Sendmail parts in order:

% [EMAIL PROTECTED]:/root# cat -n ~build/rebuild-sendmail.sh 
%  1  #!/bin/sh
%  2  
%  3  DIRS=
%  4  DIRS=${DIRS} ./lib/libmilter
%  5  DIRS=${DIRS} ./lib/libsm
%  6  DIRS=${DIRS} ./lib/libsmdb
%  7  DIRS=${DIRS} ./lib/libsmutil
%  8  DIRS=${DIRS} ./libexec/mail.local
%  9  DIRS=${DIRS} ./libexec/smrsh
% 10  DIRS=${DIRS} ./bin/rmail
% 11  DIRS=${DIRS} ./usr.bin/vacation
% 12  DIRS=${DIRS} ./usr.sbin/editmap
% 13  DIRS=${DIRS} ./usr.sbin/mailstats
% 14  DIRS=${DIRS} ./usr.sbin/makemap
% 15  DIRS=${DIRS} ./usr.sbin/praliases
% 16  DIRS=${DIRS} ./usr.sbin/sendmail
% 17  
% 18  export MAKEOBJDIRPREFIX=/home/build/obj
% 19  
% 20  for dname in ${DIRS} ; do
% 21  ( cd ${dname}  make clean  make  make install )
% 22  if test $? -ne 0 ; then
% 23  echo 
% 24  echo  FAILED while rebuilding ${dname}
% 25  exit 1
% 26  fi
% 27  done
% [EMAIL PROTECTED]:/root# 

Note that you may have to tweak the paths of this script (especially the
`MAKEOBJDIRPREFIX' part) and run it from `/usr/src' instead of my local
`/home/build/src' tree.

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: dual boot; Linux, FreeBSD

2006-06-11 Thread Giorgos Keramidas
On 2006-06-10 22:44, Jerry McAllister [EMAIL PROTECTED] wrote:
   much excised ---
   Anyway, this all works just fine.  The MBR and initial boot
   record in the boot sector of each slice (or primary
   partition if you must degrade to MS terminology) have just
   enough standardization that the FreeBSD MBR or most any of
   the other more fancy ones, can initiate the boot for any of
   the OS-en commonly available to run on these machines.
   Since the OS specific stuff really comes after it gets in
   to the slice boot record code in the boot sector, then
   generally any of them can boot any of them.  The exception
   is MS MBRs.  I have heard that some more recent ones play
   better, but any I have had so far will not boot any slice
   except one for a MS OS.   I don't know what they screw up,
   but find it not surprising.
  
   So, there is the tome.
   All newbies, careful what you ask.  Someone may answer
   thusly with more than you every wanted to know.
 
  Maybe this ought to be included in the handbook. I've seen
  this question or one like it 100's of times on these lists.
  That was the best answer I've seen.
  Just my $.02

 Thanks for the positive comment.
 It glosses over stuff a little and isn't precisely correct in
 all detail, but I think it generally is correct and represents
 the way things work for all practical matters.

 Maybe it can be a FAQ.   How do they get there?

Hi Jerry,

Can you check if we can massage it a bit and then make it a part of:
http://www.freebsd.org/doc/en_US.ISO8859-1/books/arch-handbook/boot.html

I can do the integration with the current book text, SGMLify your text,
and commit the resulting changes with a little help from you :)

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: On mail principles

2006-06-09 Thread Giorgos Keramidas
On 2006-06-08 23:15, Andrey Slusar [EMAIL PROTECTED] wrote:
Thu, 8 Jun 2006 02:08:53 +0300, Giorgos Keramidas wrote:
[...]
 I use mutt, which has an option to set the envelope-from address:

 set envelope_from=yes# set the envelope-from address from From:

 For the rest of the programs, like mail(1), my Sendmail setup sets
 envelope-from to one of my valid outside-world addresses.  This is
 accomplished with the following in my `sendmail.mc' file:

 You need write the howto sendmail for newbies :)

Thanks.  I keep saying to myself that we need task-based guides in our
Handbook, separated by user-type (i.e. Sendmail for FreeBSD Users,
Sendmail for FreeBSD Administrators, etc.)

Right now, I don't have the time to do something like this, but summer
and vacations is a good period for a bit of this sort of work :)


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: On mail principles

2006-06-09 Thread Giorgos Keramidas
On 2006-06-09 16:37, Andrey Slusar [EMAIL PROTECTED] wrote:
 Thu, 8 Jun 2006 02:08:53 +0300, Giorgos Keramidas wrote:
 
  For the rest of the programs, like mail(1), my Sendmail setup sets
  envelope-from to one of my valid outside-world addresses.  This is
  accomplished with the following in my `sendmail.mc' file:
 
  dnl Trusted users, who are allowed to change their envelope-from address
  dnl without generating a warning in the message header, are listed, one 
  per
  dnl line, in `sendmail.ct'.
  define(`confCT_FILE', `-o /etc/mail/sendmail.ct')
  FEATURE(`use_cw_file')dnl
^^^
 Small mistake - FEATURE(`use_ct_file')dnl.

Ah, thanks!  I knew I would do something stupid by copy-pasting only
the relevant bits from my real *.mc file :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Sendmail = mind boggling

2006-06-09 Thread Giorgos Keramidas
On 2006-06-09 20:34, Freminlins [EMAIL PROTECTED] wrote:
 Hello,
 I've always steered clear of using Sendmail (prefering Exim),
 but I thought I would give it a try and am having real
 difficulties with something I think should be simple.

Setting up an email server is not really a simple thing to do.

 I want to keep running Exim on port 25. I want Sendmail to run
 on a different port. So I am trying to use the
 O DaemonPortOptions=Port=2525 option. However, I have 6 cf
 files in /etc/mail - freebsd.cf, mail.xxx.co.uk.submit.cf,
 freebsd.submit.cf, sendmail.cf, mail.xxx.co.uk.cf and
 submit.cf.  I've tried all sorts of combinations of adding the
 above option to these files, but whenever I try to start
 Sendmail this error:
 sm-mta[52968]: NOQUEUE: SYSERR(root): opendaemonsocket: daemon Daemon0: 
 cannot bind: Address already in use.

This is probably because Sendmail tries to bind port 25 too,
which is taken over by Exim.

Do you *really* have to run both Sendmail and Exim on the same
host?  It may be a good idea to run Sendmail within a jail, and
set it up to listen for connections only on the jail's IP address.

 Which file(s) am I supposed to put this option into?
 I just don't understand.

The `mail.xxx.co.uk.mc' file is the right one.  If you are
putting it anywhere else, you are doing something that is wrong.

 Is it correct, also, that I have 6 cf files? I set this up as
 per the handbook. At this rate I know why I've always used Exim :-)

The Handbook doesn't mention any way to set the DaemonPortOptions
stuff, as far as I can tell:

$ cd ~/ws/bsd/doc/en_US.ISO8859-1/books/handbook
$ fgrep -r DaemonPortOption .
$

So you must have been following other instructions too.  What are
those instructions?

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: On mail principles

2006-06-08 Thread Giorgos Keramidas
On 2006-06-08 08:05, [EMAIL PROTECTED] wrote:
On Thu, Jun 08, 2006 at 02:08:53AM +0300, Giorgos Keramidas wrote:
 On 2006-06-07 20:20, [EMAIL PROTECTED] wrote:
  A brief:
  How to use envelope from provided that I have a mailbox on ISP.
  [...]

 [description of a masquerading+genericstable Sendmail setup]

 This is exactly what I want.
 Thank you.

Cool!  If you need more help setting things up, let us know :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: __P macro

2006-06-08 Thread Giorgos Keramidas
On 2006-06-08 10:45, Saifi [EMAIL PROTECTED] wrote:
 Hi:

 Most of the racoon code uses __P macro.

 and the __P macro is defined as -

 #undef __P
 #ifndef __P
 #if __STDC__
 #define __P(protos) protos
 #else
 #define __P(protos) ()
 #endif
 #endif

 It seems to make many expressions difficult to read -
 eg.

 static int (*pkrecvf[]) __P((caddr_t *)) = {
  ...
 }

 What is the downside if this macro is not used in defining new
 function prototypes ?  (working with FreeBSD 5.4 and above with
 gcc 3.x compiler)

Your program may fail to compile with compilers that do not
support ANSI C function prototypes.  This includes some old,
pre-ANSI compilers.  How important these compilers are for your
particular application is debatable though.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: On mail principles

2006-06-07 Thread Giorgos Keramidas
On 2006-06-07 20:20, [EMAIL PROTECTED] wrote:
 A brief:

 How to use envelope from provided that I have a mailbox on ISP.

 A full explanation:

 My computer has no static IP-address, nor DNS-name in Internet.
 Internally, it has static name localhost and static IP-address 127.0.0.1.

 So, I have a mail address [EMAIL PROTECTED].
 But I cannot send a mail to the world using this address in envelope from
 because of
 1) Internet MTAs cancel mail whith such an address in envelope from;
 2) such an address is useless to recipient.

 My address in the world is [EMAIL PROTECTED].  So, I make my MUA to send a
 letter using a command setting envelope from to [EMAIL PROTECTED].  (like
 sendmail -f [EMAIL PROTECTED] for sendmail, see X-Authentication-Warning in
 the header of this mail) But this way is bad for local purposes: my
 MTA's diagnostic messages are sent trough internet or lost at all,
 e. g. when my ADSL is in down.  (Moreover, my letters sent to other
 local users have non-local envelope from address. Then local mail
 begin to go through external MTA.)

 What to do in such a situation?

I use mutt, which has an option to set the envelope-from address:

set envelope_from=yes# set the envelope-from address from From:

For the rest of the programs, like mail(1), my Sendmail setup sets
envelope-from to one of my valid outside-world addresses.  This is
accomplished with the following in my `sendmail.mc' file:

dnl Trusted users, who are allowed to change their envelope-from address
dnl without generating a warning in the message header, are listed, one per
dnl line, in `sendmail.ct'.
define(`confCT_FILE', `-o /etc/mail/sendmail.ct')
FEATURE(`use_cw_file')dnl

dnl Allow mail routing exceptions through a mailer table.
FEATURE(`mailertable', `hash /etc/mail/mailertable')

dnl Address masquerading.
dnl
dnl Making sure that all email that passes through my desktop's Sendmail
dnl installation is masqueraded as coming from `gothmog.pc', even if its 
original
dnl address is something slightly different (i.e. `ftp.pc' or `mail.pc'), is
dnl ok here.  It ensures that address rewriting and translation through
dnl `genericstable' will also work for all `*.pc' host names.
dnl
dnl To make sure that remote hosts don't get a MAIL FROM address from a
dnl hostname that doesn't resolve, envelope addresses are masqueraded too, 
and
dnl then get rewritten by `genericstable' to real-world addresses,
dnl i.e. [EMAIL PROTECTED]'.
MASQUERADE_AS(`gothmog.pc')
FEATURE(`masquerade_entire_domain')
FEATURE(`masquerade_envelope')

dnl Rewriting the envelope-from address of all outgoing messages through a
dnl `genericstable' lookup, ensures that envelope-from addresses seen by 
relay
dnl hosts are real, i.e. [EMAIL PROTECTED]' instead of the default
dnl envelope-from of [EMAIL PROTECTED]' that Sendmail would use.  This is
dnl required some times, to avoid getting bounces for messages from ISP mail
dnl relays that are misconfigured or are too strict about what can appear 
in a
dnl MAIL FROM command.
FEATURE(`genericstable', `hash -o /etc/mail/genericstable')
GENERICS_DOMAIN(`gothmog.pc')
FEATURE(`generics_entire_domain')

This looks like quite a mouthful of options, but it's not really that
difficult to read.  It's only big because of all the comments.

The file `/etc/mail/sendmail.ct' contains my username, because I trust
myself to use valid envelope-from addresses.  This turns off the
X-Authentication-Warning header which is so annoying for you too.

Then, in `/etc/mail/mailertable' I have an exception for my internal,
work-related email, and send it directly to the company's mail gateway:

# Custom mail routing rules.  This is currently useful only
# for routing work-related email through the VPN connection
# to my company's mail relay.
#
foo.com smtp:mailgate.foo.com
.foo.comsmtp:mailgate.foo.com

Finally, in my `/etc/mail/genericstable' map, I rewrite the
envelope-from of all the rest of email messages, like this:

# Outgoing email address rewriting.
[EMAIL PROTECTED]   [EMAIL PROTECTED]
[EMAIL PROTECTED]   [EMAIL PROTECTED]
[EMAIL PROTECTED]   [EMAIL PROTECTED]

These options are, of course, just a suggestion.  You don't *HAVE* to
use a setup similar to mine.

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Sorry for the old emails to this list

2006-05-31 Thread Giorgos Keramidas
On 2006-05-30 19:09, Aaron Holmes [EMAIL PROTECTED] wrote:
 I just fixed my mail server, and it looks like it was waiting
 to push those forward :)

Heh!  That's ok, I guess.  It means you really fixed it :-)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Mounting to a second hard disk

2006-05-31 Thread Giorgos Keramidas
On 2006-05-31 08:37, Kevin Kinsey [EMAIL PROTECTED] wrote:
Philip Radford wrote:
Hi All,
 I have just installed FreeBSD 5.4 on a server with two hard disks.

 Cool ... :)

Nice :)

 I have access to all my partitions on the first disk :-

 /dev/ad0s1a - /
 /dev/ad0s1e - /tmp
 /dev/ad0s1f - /usr
 /dev/ad0s1d - /var

 How do I go about mounting to the second drive which I
 assume would start with /dev/ad1*

 $ dmesg | grep ad

Another way is through atacontrol:

# atacontrol list
ATA channel 0:
Master:  ad0 WDC WD2000JB-98GVA0/08.02D08 ATA/ATAPI revision 6
Slave:   no device present
ATA channel 1:
Master:  no device present
Slave:   no device present
ATA channel 2:
Master:  ad4 WDC WD2500JS-55NCB1/10.02E01 Serial ATA II
Slave:   no device present
ATA channel 3:
Master:  no device present
Slave:   no device present

Then you can use fdisk/bsdlabel/newfs on ad2 as usual :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: using bsdlabel

2006-05-31 Thread Giorgos Keramidas
On 2006-05-31 15:30, Robert Huff [EMAIL PROTECTED] wrote:

   I've never used bsdlabel before; would someone please confirm
 I've got this right?
   Status quo:

 huff@ bsdlabel da0s1
 # /dev/da0s1:
 8 partitions:
 #size   offsetfstype   [fsize bsize bps/cpg]
   a:  102400004.2BSD0 0 0
   b:  2097152  1024000  swap
   c:  89160120unused0 0 # raw part, don't 
 edit
   d:  2097152  31211524.2BSD0 0 0

   As I understand it, if I run this:

 huff@ bsdlabel -w da0s1 -f /label.new

   where /label.new has:

 # /dev/da0s1:
 8 partitions:
 #size   offsetfstype   [fsize bsize bps/cpg]
   a:  102400004.2BSD0 0 0
   b:  2097152  1024000  swap
   c:  89160120unused0 0 # raw part, don't 
 edit
   d:  2097152  31211524.2BSD0 0 0
   e:  3697708  51283044.2BSD0 0 0

   this will allocate the rest of the slice to partition 'e'.
 (And we're ready to newfs.)

Yes, this looks ok :)

The 'e' partition can only start *after* the 'd' partition, so it should
have an offset of:


'd' start  + 'd' size
-
3121152+ 2097152  = 5218304

The 'rest' of the disk is:

'c' size   - 'e' start
 -
8916012- 5218304   = 3697708

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Saving output of an application

2006-05-30 Thread Giorgos Keramidas
On 2006-05-30 21:52, Lars Stokholm [EMAIL PROTECTED] wrote:
 I don't know how to explain this, but I remember that there is some
 way of saving everything that's going on in the terminal, I just don't
 remember the command for doing so. I think it's something along the
 lines of (e.g.):

 # something file.name (this would start logging)
 # portupgrade -a (or anything else)
 # someting something (this would stop logging and close the file)

 file.name would then contain all of the output of portupgrade. Can
 someone help me with the right command? :)

The script(1) utility is the one you are looking for.

If you are using bash or a Bourne shell, you can also use:

$ cmd 21 | tee logfile

or when multiple commands are involved, parentheses:

$ ( cmd ; cmd2 ) 21 | tee logfile

I use the Bourne shell redirection trick to save the output of builds,
for instance:

csh# sh
$ cd /usr/src
$ ( make KERNCONF=FOO buildworld buildkernel ) 21 | tee logfile


It comes very handy whenever I need to go back and see the log of
the build :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Greek Accents and Filenames

2006-05-25 Thread Giorgos Keramidas
On 2006-05-25 14:50, andreas Sotirakopoulos [EMAIL PROTECTED] wrote:
 HI
 I have a problem writing Greek accents in KDE. I am using KDE
 3.5 on freebsd 6.1 and although i can type Greek in all
 applications i cannot put accents.  Accents are placed by
 hitting the ; before the letter. When i do so though nothing
 happen, in fact even the letter is not appearing on the screen.
 I have tried typing export LC_CTYPE=el_GR on the console and
 rebooting but then when i type locale i get:

 LANG=
 LC_CTYPE=C
 LC_COLLATE=C
 LC_TIME=C
 LC_NUMERIC=C
 LC_MONETARY=C
 LC_MESSAGES=C
 LC_ALL=

Your Greek locale setup is messed up.  I don't know why you have
all these, but if they are in your ~/.bashrc or something remove
them all and use something like this:

# Locale setup.
export LANG=C
export LC_CTYPE=el_GR.ISO8859-7
export LC_COLLATE=el_GR.ISO8859-7
unset LC_ALL LC_MESSAGES LC_MONETARY LC_NUMERIC LC_TIME

Your locale setup looks very close to what I've seen on Linux
systems, but the set of LC_xxx environment variables you have now
is _not_ going to work with FreeBSD.

 Moreover although i can read greek on konqueror and opera i
 cannot do so on Kwrite or i cannot read greek filenames on the
 desktop, eventhough ei can give greek names on files whithout
 accents ofcourse.

Random problems with accents are very often a hint that points
towards invalid/wrong locale setup.  Fix your environment
*before* you start X11, make sure that you don't override the
fixed environment in your X11 configuration with something else,
and you should be set to go :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: :::. Sendmail on FreeBSD - Deferred: Operation timed out with server

2006-05-21 Thread Giorgos Keramidas
On 2006-05-20 14:30, Mikhail Goriachev [EMAIL PROTECTED] wrote:
 Giorgos, Kevin, thanks a lot for your input. Finally this madness is
 getting some explanation. I was getting a few beers short of a carton on
 this one. hospitaldeninos.cl has got some config issues:

 http://www.dnsreport.com/tools/dnsreport.ch?domain=hospitaldeninos.cl

Cool report!  This explains a lot :-)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: :::. Sendmail on FreeBSD - Deferred: Operation timed out with server

2006-05-19 Thread Giorgos Keramidas
On 2006-05-20 02:20, Mikhail Goriachev [EMAIL PROTECTED] wrote:
 Hi,

 Sendmail and I aren't getting along well. I got this FreeBSD
 6.0-RELEASE-p7 box doing SMTP work for me. Everything is fine, but a few
 domains give me headaches with Deferred: Operation timed out with
 server here errors. One domain in particular I'm trying to get to
 work is hospitaldeninos.cl

 $ host hospitaldeninos.cl
 hospitaldeninos.cl has address 200.31.44.1
 mail is handled by 4 nt_sql_server2.hospitaldeninos.cl.
 mail is handled by 5 mail.hospitaldeninos.cl.

 Whenever I try to send anything to that domain I just get the following
 in my logs:

 [...] delay=01:00:57, xdelay=00:01:15, mailer=esmtp, pri=210425,
 relay=mail.hospitaldeninos.cl. [200.29.150.146], dsn=4.0.0,
 stat=Deferred: Operation timed out with mail.hospitaldeninos.cl.

For some reason, your Sendmail setup tries to find out the IP address of
the MX for `hospitaldeninos.cl' and it resolves this to the wrong mail
server:

mail.hospitaldeninos.cl

This would tend to work fine, as long as either one of the two MX hosts
of the domain accepted email, but there are also problems connecting to
the `mail.hospitaldeninos.cl:SMTP' service too.

What do the following files contain in the FreeBSD system that fails to
resolve the MX records correctly?

/etc/hosts
/etc/resolv.conf
/etc/host.conf
/etc/nsswitch.conf

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: :::. Sendmail on FreeBSD - Deferred: Operation timed out with server

2006-05-19 Thread Giorgos Keramidas
On 2006-05-20 05:04, Mikhail Goriachev [EMAIL PROTECTED] wrote:
Giorgos Keramidas wrote:
 For some reason, your Sendmail setup tries to find out the IP
 address of the MX for `hospitaldeninos.cl' and it resolves
 this to the wrong mail server:

 mail.hospitaldeninos.cl

 This would tend to work fine, as long as either one of the two
 MX hosts of the domain accepted email, but there are also
 problems connecting to the `mail.hospitaldeninos.cl:SMTP'
 service too.

 What do the following files contain in the FreeBSD system that
 fails to resolve the MX records correctly?

  /etc/hosts /etc/resolv.conf
  /etc/host.conf
  /etc/nsswitch.conf

 Thanks for quick response. These are the files:

 /etc/hosts
 127.0.0.1 localhost.tas.webanoide.org localhost
 192.168.0.2 kavayito.tas.webanoide.org kavayito

 /etc/resolv.conf
 search tas.webanoide.org
 nameserver 192.168.0.1

 /etc/host.conf
 hosts
 bind

 /etc/nsswitch.conf
 hosts: files dns

I see.  Does the nameserver at 192.168.0.1 reply with correct
data for the `hospitaldeninos.cl' domain?  It seems that your
Sendmail gets `mail.hospitaldeninos.cl' as the primary MX for
that domain from somewhere, but it isn't obvious from these files
where the wrong reply comes from.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: :::. Sendmail on FreeBSD - Deferred: Operation timed out with server

2006-05-19 Thread Giorgos Keramidas
On 2006-05-19 22:50, Giorgos Keramidas [EMAIL PROTECTED] wrote:
 I see.  Does the nameserver at 192.168.0.1 reply with correct data for
 the `hospitaldeninos.cl' domain?  It seems that your Sendmail gets
 `mail.hospitaldeninos.cl' as the primary MX for that domain from
 somewhere, but it isn't obvious from these files where the wrong reply
 comes from.

Hmmm, maybe I know why DNS resolution fails:

$ uname -a
Linux  2.6.10 #1 Thu Dec 30 03:01:16 EET 2004 i686 GNU/Linux
$ host nt_sql_server2.hospitaldeninos.cl 200.31.44.1
nt_sql_server2.hospitaldeninos.cl   A   200.29.150.147
 !!! nt_sql_server2.hospitaldeninos.cl A record has illegal name
$ host nt_sql_server2.hospitaldeninos.cl 200.31.43.33
nt_sql_server2.hospitaldeninos.cl   A   200.29.150.147
 !!! nt_sql_server2.hospitaldeninos.cl A record has illegal name
$

The hostname contains underscores, which is not a legal character for a
hostname.  This way *SOME* systems fail to resolve this hostname and
fall back to using mail.hospitaldeninos.cl as the MX for this domain.

But that system doesn't reply to SMTP connections at all.

Hence the email failures.

So, there are two problems here:

* The primary MX has an invalid character in its hostname.

* The secondary MX is not-working at all.

I think this explains why your Sendmail is complaining about being
unable to deliver email to that domain.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: kernel module for ipf

2006-05-18 Thread Giorgos Keramidas
On 2006-05-18 12:05, Michael P. Soulier [EMAIL PROTECTED] wrote:
 Hello,

 The handbook mentions that ipf should work out of the box in FreeBSD
 thanks to a kernel module, but it doesn't say which one.

 http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/firewalls-ipf.html

 IPF is included in the basic FreeBSD install as a separate run time
 loadable module. The system will dynamically load the IPF kernel
 loadable module when the rc.conf statement ipfilter_enable=YES is
 used. The loadable module was created with logging enabled and the
 default pass all options. You do not need to compile IPF into the
 FreeBSD kernel just to change the default to block all, you can do
 that by just coding a block all rule at the end of your rule set.

 I don't see anything under /boot/kernel that looks like a likely
 candidate. There's an ipfw.ko, but no ipf or ipfilter. I'd prefer to
 not reboot my system just to find out, so could someone point me to
 the correct module? I'm running FreeBSD 5.4 with the GENERIC kernel.

The module is called ipl.ko:

# ls -l /boot/kernel/ipl.*
-r-xr-xr-x  1 root  wheel  - 171625 May 16 16:05 /boot/kernel/ipl.ko
-r-xr-xr-x  1 root  wheel  - 371887 May 16 16:05 /boot/kernel/ipl.ko.symbols
#

Strange and weird, but this is the name the IP Filter kernel module
has had for years, so it's not easy to change it now without breaking
all the scripts around the world that assume its name is ipl.

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Firewall Speed

2006-05-18 Thread Giorgos Keramidas
On 2006-05-18 11:03, bc [EMAIL PROTECTED] wrote:
 I want to run 6.1_RELEASE with Packet Filter(PF) configured as
 a gateway using 2 identical 10/100 nics, on an old 450mhz
 pentium with 256 meg ram and an 8 gig HD.

 In general, should I expect any speed performance issues with
 internet access base on the processor, ram and bus speeds of
 the MB?  Would the PF config cause any speed performance
 deficiencies?

 I had same setup as above but with IPF firewall and received
 complaints about surfing speed so I put them back on a Linksys
 router firewall.

We'd have to see the ruleset to be able to reply in an informed
manner.  I have seen firewalls doing both filtering  NAT on a
system, with almost no overhead at all though.

This top output:

http://keramida.serverhive.com/pixelshow-top.txt

shows that a FreeBSD 5.X system with 256 MB of physical memory is
happily filtering the traffic and doing NAT for more than 100
users, while still being 97% idle.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: kernel module for ipf

2006-05-18 Thread Giorgos Keramidas
On 2006-05-18 12:52, Michael P. Soulier [EMAIL PROTECTED] wrote:
 On 5/18/06, Scott Mitchell [EMAIL PROTECTED] wrote:
 You want the ipl.ko module.  No, I have no idea why it's called ipl not ipf
 either...

 [EMAIL PROTECTED] ~]# ls /boot/kernel/ipl*
 /boot/kernel/ipl.ko*

 Ah. Cool. Thanks.
 Yes, this should be in the handbook.

I'll try to add it :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: how to search keywords in all directories

2006-05-18 Thread Giorgos Keramidas
On 2006-05-18 15:22, jason zeng [EMAIL PROTECTED] wrote:
 Hello!

 our system is runing on FreeBSD 5.3. using php+mysql. now I
 take over codes(programs) management and maintains.there are a
 lots of .php code and Database tables. what I have now are
 database, tables structures, and just a few programs
 description. so I don't know the relationship in these php
 programs. I really need read these programs when sometime it
 has something wrong.I have to do these troubleshooting.

 I want to know if there are some shortcut way to speed up my
 work.  there is a common program in my system that many others
 call it.the common.php hase many classes and functions, for
 example, function displaySelect(), I hope to find how many
 programs call this function and where these programs are? how
 can I search them using Unix command (s)? What I know is all
 php programs are at /usr/local/php/html directory.from there,
 there are many sub-directories.

[Text wrapped]

Please try capitalizing sentences  wrap your text using a more
reasonable line length (i.e. 72-75 characters per line).  It is
awful trying to read stuff like the original.

I think what you are looking for is something like:

$ cd /usr/local/php/html
$ find . -type f | xargs fgrep common.php

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: how to search keywords in all directories

2006-05-18 Thread Giorgos Keramidas
On 2006-05-18 16:01, jason zeng [EMAIL PROTECTED] wrote:
 Hello! Giorgos,

 Thanks for your response. It is very useful for me. I tried it
 works!  so I don't warry at weekend to read a lots of programs
 at home. :-)

Great!  A good guide about shell scripting will help in similar
casesin the future, i.e. the ``Advanced Bash-Scripting Guide'' of
the Linux Documentation Project:

http://www.tldp.org/LDP/abs/html/

Have fun,

Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: C coding question

2006-05-17 Thread Giorgos Keramidas
On 2006-05-17 14:09, Andy Greenwood [EMAIL PROTECTED] wrote:
 I am helping someone work on porting some code to Freebsd, and the
 code below works on Linux, but not on FreeBSD (compiles, but gives
 Segmentation Fault: 11). I'm not sure where the problem is, and any
 pointers would be much appreciated.

/* Check if we must stop */
if(tf_stat_file != NULL)
{
tf_stat = fopen(tf_stat_file, r);
if (tf_stat != NULL)
{
/* Get state */
stat_state=fgetc(tf_stat);

/* Torrentflux asked to shutdown the torrent */
if (stat_state == '0')
{
mustDie = 1;
}
}
fclose(tf_stat);
}

Please post a complete, compilable program or at least details about
where we can find the full source.  This way it's impossible to find out
where the bug is and why the segmentation fault happens.


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Is MAXFILES still valid in a kernel config option?

2006-05-16 Thread Giorgos Keramidas
On 2006-05-16 11:35, Bill Moran [EMAIL PROTECTED] wrote:

 Using 6.1, is MAXFILES still honored in the kernel config?

 I know I can adjust this via sysctl, but setting it in the kernel config
 is more conducive to our deployment methodology.

Yes.  The option is still valid even in CURRENT.

The `src/sys/kern/subr_param.c' file contains:

 64 #ifndef MAXFILES
 65 #define MAXFILES (maxproc * 2)
 66 #endif

and the option is still present in `src/sys/conf/NOTES'.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Is MAXFILES still valid in a kernel config option?

2006-05-16 Thread Giorgos Keramidas
On 2006-05-16 13:28, Bill Moran [EMAIL PROTECTED] wrote:
On Tue, 16 May 2006 19:06:45 +0300
Giorgos Keramidas [EMAIL PROTECTED] wrote:
On 2006-05-16 11:35, Bill Moran [EMAIL PROTECTED] wrote:

 Using 6.1, is MAXFILES still honored in the kernel config?

 I know I can adjust this via sysctl, but setting it in the
 kernel config is more conducive to our deployment
 methodology.

 Yes.  The option is still valid even in CURRENT.

 The `src/sys/kern/subr_param.c' file contains:

  64 #ifndef MAXFILES
  65 #define MAXFILES (maxproc * 2)
  66 #endif

 and the option is still present in `src/sys/conf/NOTES'.

 Thanks.  I thought it a little odd that NOTES groups it under
 this category:
 # Yet more undocumented options for linting.

 Seemed like something that was liable to silently break ...

I'm not sure what the real plans are around there, but (AFAIK) at
least for the RELENG_6 branch, now that the option is part of
RELENG_6 it should remain there for the entire lifetime of the
branch :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Rebuilding Man database

2006-05-15 Thread Giorgos Keramidas
On 2006-05-14 23:30, Andrew Carton [EMAIL PROTECTED] wrote:
 Disturbingly, some of my man pages are not working, i.e. man man comes
 up with nothing is there a way to rebuild the man database to fix
 this?

Try to remove any stale cat pages (preformatted manpage files):

 # /usr/share/man
 # find cat* -type f | xargs rm -f

Repeat the same for any other directories in your MANPATH, and see if
that fixes the problems you are seeing...

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Newbie File system

2006-05-15 Thread Giorgos Keramidas
On 2006-05-15 17:20, Maan Jee [EMAIL PROTECTED] wrote:
 Hi

 Can someone explane that at which filesystem is my /home directory
 located?


 Filesystem  1K-blocksUsedAvail Capacity  Mounted on
 /dev/ad0s1a50763055002   412018  12%/
 devfs   1   1   0 100%/dev
 /dev/ad0s1e507630  12   467008   0%/tmp
 /dev/ad0s1f  34336100 1564298 30024914 5%/usr
 /dev/ad0s1d   150619024892  1360804  2%/var

You can find for yourself:

# ls -ld /home

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Given this chunk of makefile, how do I set this to build the plugin?

2006-05-13 Thread Giorgos Keramidas
On 2006-05-13 09:42, Oliver Iberien [EMAIL PROTECTED] wrote:
 This is from the latest port of gnash. I can't coax it into building
 the plugin. What is the option I pass to make to get it to build?

  +OPTIONS=  PLUGIN  Enable firefox plugin off
  +
  +.include bsd.port.pre.mk
  +
  +.if !defined(WITH_PLUGIN)
  +CONFIGURE_ARGS+=  --disable-plugin
  +PLIST_SUB+=   PLUGIN=@comment 
  +.else
  +USE_GNOME+=   atk pango gtk20
  +LIB_DEPENDS+= gtkglext-x11-1.0.2:${PORTSDIR}/x11-toolkits/gtkglext
  +PLIST_SUB+=   PLUGIN=
  +.endif

The Makefile supports the 'OPTIONS' configuration stuff.  So, to make
sure it's reconfigured, start with:

# cd /usr/ports/graphics/gnash
# make rmconfig

Then rebuild the port, and you should see a menu of options.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Trimming Whitespace From Beginning and end of Text Lines

2006-05-12 Thread Giorgos Keramidas
On 2006-05-12 09:50, Martin McCormick [EMAIL PROTECTED] wrote:
   This looks like something sed should be able to do, but I
 haven't had any luck at all.  I wanted to remove any whitespace
 that has accidentally gotten added to the beginning or end of
 some lines of text.  I made a test file that looks like:

 left justified.
  lots of spaces.

 and the best I have done so far is to get rid of about 3 spaces.

 Attempt 1.

 #! /usr/bin/sed -f
 s/ \+//g
 s/^ //g
 s/ $//g

This fails to remove TAB characters from either the start or the
end of a line.

   This looks like it should do the job, but the leading and
 trailing spaces are still mostly there.

   I wrote another script.  Attempt 2.

 #! /bin/sh

 sed 's/^[[:space:]]//g' \
 |sed 's/[[:space:]]$//g'

This fails to remove multiple occurences of the [[:space:]] class.

There are at least the following ways:

sed -i -e 's/^[[:space:]]*' -e 's/[[:space:]]*$//' file ...
perl -pi -e 's/^\s*(\S.*\S)[ \t]*$/$1/' file ...

The first one seems more straightforward to me most of the time,
but there are times I find Perl's `-pi -e ...' idiom very convenient.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Trimming Whitespace From Beginning and end of Text Lines

2006-05-12 Thread Giorgos Keramidas
On 2006-05-12 11:27, Chuck Swiger [EMAIL PROTECTED] wrote:
Giorgos Keramidas wrote:
 This fails to remove multiple occurences of the [[:space:]] class.

 There are at least the following ways:

  sed -i -e 's/^[[:space:]]*' -e 's/[[:space:]]*$//' file ...
  perl -pi -e 's/^\s*(\S.*\S)[ \t]*$/$1/' file ...

 The first one seems more straightforward to me most of the time,
 but there are times I find Perl's `-pi -e ...' idiom very convenient.

 It is, and I wish to acknowledge the above are entirely valid solutions
 to the problem, but...

   python -c 'import sys; print sys.stdin.read().strip()'  file...

 ...has the advantage of being human readable.  My old 300-baud accoustic
 modem used to generate output which in hindsight looks astonishingly
 close to regex character classes.  :-)

HEH!  I see the joke about Perl being similar to line noise is not
something local to our Greek IRC channels :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Trimming Whitespace From Beginning and end of Text Lines

2006-05-12 Thread Giorgos Keramidas
On 2006-05-12 17:56, [EMAIL PROTECTED]@mgEDV.net [EMAIL PROTECTED] wrote:
 sed -i -e 's/^[[:space:]]*' -e 's/[[:space:]]*$//' file ...

 why not use just (you can change the - separator to / as above):
 sed -e 's-^ *--g' -e 's- *$--g'

Because this provides no additional help with the problem of not
matching TABS and it looks very confusing so close to `-e' and other
command-line options.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Trimming Whitespace From Beginning and end of Text Lines

2006-05-12 Thread Giorgos Keramidas
On 2006-05-12 10:41, Warren Block [EMAIL PROTECTED] wrote:
On Fri, 12 May 2006, Giorgos Keramidas wrote:
 There are at least the following ways:

sed -i -e 's/^[[:space:]]*' -e 's/[[:space:]]*$//' file ...
perl -pi -e 's/^\s*(\S.*\S)[ \t]*$/$1/' file ...

 The first one seems more straightforward to me most of the
 time, but there are times I find Perl's `-pi -e ...' idiom
 very convenient.

 Neither of those work here:

 The first sed expression is missing //.  Correcting that:
   sed -i -e 's/^[[:space:]]*//' -e 's/[[:space:]]*$//' test.txt
   sed: lstat: No such file or directory

Yeah, I noticed the missing // in the first regexp, but only
after I had posted the message.  You're right, of course :)

It seems odd that the fixed expression doesn't work though.
Which version of FreeBSD is this and what sed are you running?

$ uname -v
$ type sed

 The Perl version shows no difference between the original and
 processed file.  It's complex, too.  This one works:

   perl -pi -le 's/^\s+//; s/\s+$//' test.txt

 Notes:
 1. sed always seems to be a pain.  My compliments to those who use it
regularly; the only time I use it at all is when Perl (or something
else with better handling of regular expressions) is not available.
 2. The -l option to perl is needed to preserve line endings.
 3. The last version is based on the more efficient way of doing it as
per: man -P 'less +/trim' perlop

Great!  Thanks for all the useful tips :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: daemon to listen on localhost only?

2006-05-10 Thread Giorgos Keramidas
On 2006-05-10 12:59, Sean Murphy [EMAIL PROTECTED] wrote:
 Is there a way to tell a daemon to listen only to the localhost without
 using a firewall?

This depends on the daemon.  Some programs accept a command-line option
to do this.  Others don't.

What daemon are you interested in doing this for?

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Fwd: New freebsd logo on freebsd.org

2006-05-09 Thread Giorgos Keramidas
On 2006-05-09 10:57, [EMAIL PROTECTED] wrote:
At 07:01 AM 5/9/2006, you wrote:
 I have to agree with the original poster. The logo is crap,
 and so is the font they've started to use since the
 announcement of FreeBSD6.1-RELEASE. At

 Me Too.  At first I thought it was just a petty complaint.

 But if you're trying to sell FreeBSD to a boss or customer, a
 serious, business-like web site surely helps.  The new one
 seems to borrow too much from the hax0r community's
 appearance.

 And the font overflows and looks like complete shit on my
 browser; usually this would just be blamed on using a Non
 Microsoft Browser (FireFox on windoze) but until we have IE
 for FBSD, it seems a legit complaint.

I'm not a fan of the new logo either, but having said that, the
integration of the new logo with the website was done only this
morning.  Let's give it some time to settle in and have all the
problems solved, shall we?

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: About Bison and Flex

2006-05-09 Thread Giorgos Keramidas
On 2006-05-09 10:38, Robe [EMAIL PROTECTED] wrote:
 Hi,
 I'm a new user of FreeBSD and I want to know if the Bison parser generator
 and Flex for Linux is available here.

Yes.

$ which lex yacc
/usr/bin/lex
/usr/bin/yacc
$ which flex
/usr/bin/flex
$ which bison
/usr/local/bin/bison
$

The base system includes lex(1) and yacc(1).  The lex(1) utility is
actually flex(1).  You can install bison(1) from the Ports  Packages
Collection, i.e. with:

# pkg_add -r bison


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: 7-CURRENT

2006-05-08 Thread Giorgos Keramidas
On 2006-05-08 14:02, Perttu Laine [EMAIL PROTECTED] wrote:
 I have 7-CURRENT-SNAP009 on one testing computer and I'd like to update it
 to latest 7 sources. So can it be done via cvsup or how can update sources
 to latest? RELENG_7 seems to just delete everything with cvsup...

There is no RELENG_7 tag (yet).  You can change that to just a single
dot character (`.'), and CVSup will pull the HEAD of the CVS branch
for you (which is `CURRENT').

Note that CURRENT is not always buildable and not always stable enough
for production use, though.  Make sure you read and understand all the
stuff explained here:

http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/current-stable.html

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Substitute command on vi

2006-05-05 Thread Giorgos Keramidas
On 2006-05-05 10:12, Aguiar Magalhaes [EMAIL PROTECTED] wrote:
 Hi list,

 I need to substitute a lot of characters ^M (ctrl+M)
 at the end of each line in my file.

 The command :%s/^M//g insn't have success.

The command looks fine, except for a tiny detail:

Make sure you use ^V ^M to insert a *literal* ^M character in the
match pattern, instead of two different characters '^' and 'M'.
Then it should work.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: cvs

2006-05-05 Thread Giorgos Keramidas
On 2006-05-05 10:45, Doug Hardie [EMAIL PROTECTED] wrote:
 I have been building a cvs structure for a bunch of code and have
 a couple questions I have not been able to find answers to in the
 archives/documentation.  When you run ident on many FreeBSD modules
 you see the identifier FreeBSD used frequently.  It appears that
 cvs is properly updating the information in those entries, but I
 don't see how cvs is configured to make that happen.  FreeBSD is not
 one of the cvs recognized keywords.  I would like to use a unique
 keyword for my stuff. ident finds it fine in the files, but cvs does
 not update the version information.  I suspect that somehow I need
 to tell cvs about the keyword.

See this article for details of the FreeBSD CVS setup:

http://www.freebsd.org/doc/en_US.ISO8859-1/articles/cvs-freebsd/

Part of this explains how our `cfg_local.pm' works and you can use a
similar trick for any custom $FreeBSD$-like keyword you want.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: ipfirewall tricks

2006-05-03 Thread Giorgos Keramidas
On 2006-05-02 20:41, Atom Powers [EMAIL PROTECTED] wrote:
On 5/2/06, Bryan Curl [EMAIL PROTECTED] wrote:
I want to limit time my kids spend on the internet.
The way I am doing it is to make varying, seperate ipf.rules files and
install them from cron at the appropriate time.
Problem is, if I make a change to one file, I generally have to update all
the others accordingly.

Is there a better way? I have read man ipf but didnt come out with any
ideas.
 
 I would use pf and have something like this:
 
 pf.conf
 
 block out all from kids to any
 
 
 crontab
 
 pfctl -t kids -T add kids.ip.to.block
 pfctl -t kids -T del kids.ip.to.allow
 
 
 You can also keep the IPs in a flat file and just tell pf to re-read
 the file (or read a different file) to update the table.

Ah, neat trick.  This is exactly why tables are so cool :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: ipfirewall tricks

2006-05-02 Thread Giorgos Keramidas
On 2006-05-02 17:35, Bryan Curl [EMAIL PROTECTED] wrote:
 I want to limit time my kids spend on the internet.  The way I am
 doing it is to make varying, seperate ipf.rules files and install them
 from cron at the appropriate time.

Sounds like a good plan.

 Problem is, if I make a change to one file, I generally have to update
 all the others accordingly.

Which files?  You can use symlinks to your advantage.  For example, if
you have two sets of rules, named `ipf.conf.allow' and `ipf.conf.block',
you can set your `/etc/rc.conf' to reference `/etc/ipf.conf' and then
use a cron job or two to symlink to one of the two :-)

00 08 * * * /root/scripts/ipf-allow.sh
00 20 * * * /root/scripts/ipf-block.sh

The scripts could be something as simple as:

|   #!/bin/sh
|   #
|   # ipf-allow.sh  - Reload IP Filter from /etc/ipf.conf.allow
|   #
|
|   # If anything goes wrong, fall back to a slightly paranoid ruleset
|   # that disallows almost *ALL* network access, letting only ICMP, DNS
|   # and SSH through.
|   paranoid_rules() {
|   { echo 'pass in  quick on lo0 all' ;
| echo 'pass out quick on lo0 all' ;
| echo 'pass in  quick proto icmp all' ;
| echo 'pass out quick proto icmp all' ;
| echo 'pass out quick proto udp from any to any port = 53 keep state' ;
| echo 'pass out quick proto tcp from any to any port = 53 keep state' ;
| echo 'pass in  quick proto tcp from any to any port = 22 keep state' ;
| echo 'pass out quick proto tcp from any to any port = 22 keep state' ;
| echo 'block in all' ;
| echo 'block out all' ;
|   } | ipf -Fa -f -
|   }
|
|   ipf_allow_rules='/etc/ipf.conf.allow'
|   ipf_rules='/etc/ipf.conf'
|
|   if test ! -f ${ipf_allow_rules} ; then
|   echo 2 ${ipf_allow_rules}: ruleset missing, blocking (almost) all 
network access.
|   paranoid_rules
|   exit 1
|   fi
|
|   /bin/rm -f ${ipf_rules}  \
|   ln -s ${ipf_allow_rules} ${ipf_rules}  \
|   ipf -Fa -f ${ipf_allow_rules}
|
|   if test $? -ne 0 ; then
|   echo 2 ${ipf_load_rules}: ruleset failed to load, blocking (almost) 
all network access.
|   paranoid_rules
|   exit 1
|   fi

A similar script for ipf_deny_rules, and you're set.  You can even join
the two scripts in one and pass the ruleset file to load in the cronjob:

00 08 * * * /root/scripts/ipf-load.sh /etc/ipf.conf.allow
00 20 * * * /root/scripts/ipf-load.sh /etc/ipf.conf.block

and then write your script as:

|   #!/bin/sh
|   #
|   # ipf-load.sh   - Reload IP Filter from $1
|   #
|
|   # If anything goes wrong, fall back to a slightly paranoid ruleset
|   # that disallows almost *ALL* network access, letting only ICMP, DNS
|   # and SSH through.
|   paranoid_rules() {
|   { echo 'pass in  quick on lo0 all' ;
| echo 'pass out quick on lo0 all' ;
| echo 'pass in  quick proto icmp all' ;
| echo 'pass out quick proto icmp all' ;
| echo 'pass out quick proto udp from any to any port = 53 keep state' ;
| echo 'pass out quick proto tcp from any to any port = 53 keep state' ;
| echo 'pass in  quick proto tcp from any to any port = 22 keep state' ;
| echo 'pass out quick proto tcp from any to any port = 22 keep state' ;
| echo 'block in all' ;
| echo 'block out all' ;
|   } | ipf -Fa -f -
|   }
|
|   if test $# -ne 1 ; then
|   echo 2 usage: ipf-load.sh ruleset-path
|   paranoid_rules
|   exit 1
|   fi
|
|   ipf_load_rules=$1
|   ipf_rules='/etc/ipf.rules'
|
|   if test ! -f ${ipf_load_rules} ; then
|   echo 2 ${ipf_load_rules}: ruleset missing, blocking (almost) all 
network access.
|   paranoid_rules
|   exit 1
|   fi
|
|   /bin/rm -f ${ipf_rules}  \
|   ln -s ${ipf_load_rules} ${ipf_rules}  \
|   ipf -Fa -f ${ipf_load_rules}
|
|   if test $? -ne 0 ; then
|   echo 2 ${ipf_load_rules}: ruleset failed to load, blocking (almost) 
all network access.
|   paranoid_rules
|   exit 1
|   fi

 Is there a better way? I have read man ipf but didnt come out with any
 ideas.

Well, the 'best' way is the one you like the most, I guess :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Boot manager beep (revisited)

2006-05-01 Thread Giorgos Keramidas
On 2006-05-01 02:05, Parv [EMAIL PROTECTED] wrote:
 Eric Anderson wrote:
 This thread:
 http://lists.freebsd.org/pipermail/freebsd-stable/2005-December/020572.html

 I hand edited the file (/usr/src/sys/boot/i386/boot0/boot0.S)
 based on the given patch; did building|installing of world 
 kernel; on reboot of Dell Inspiron 5000e laptop, there still
 was a beep.

Rebuilding everything is hardly worth it in this case, but you
did what you considered the safest thing, so that's ok :)

 So the patch did not work for me.  Did i miss something?

Yes.  You missed installing the new boot0 block on your MBR.

See my other response in this thread about the steps you have to
take to rebuild a new /boot/boot0 block and install it with
boot0cfg on the MBR of your disk :-)



pgp5zG9XUdtex.pgp
Description: PGP signature


Re: Sendmail Compile-Time Configuration - Success

2006-04-30 Thread Giorgos Keramidas
On 2006-04-30 02:55, Duane Whitty [EMAIL PROTECTED] wrote:
Giorgos Keramidas wrote:
 No, you probably want something similar to the way SASL2 support is
 compiled into the base-system version of Sendmail.  In my `make.conf'
 I have the following:

 SENDMAIL_CFLAGS=-I/usr/local/include -DSASL=2
 SENDMAIL_LDFLAGS=   -L/usr/local/lib
 SENDMAIL_LDADD= -lsasl2

 While adding stuff to these variables please keep in mind that GCC on
 FreeBSD has a major difference from the default GCC behavior: it does *not*
 add /usr/local/include to the default include path or /usr/local/lib to the
 default library search path.  So you will have to add them yourself, as
 shown above.

 Hi,

 Thank you Giorgos, this is the right direction.  Your example was most
 fortuitous, maybe even prescient. ;)

Heh!  Sheer luck, sheer luck.

 LDAP support in Sendmail requires that SASL support also be built in.

Great!  I didn't know this, but SASL is one of the examples I could
easily find in /usr/src to copy/ into the reply :-)

 SENDMAIL_CFLAGS=-I/usr/local/include -DSASL=2 -DLDAPMAP
 SENDMAIL_LDFLAGS=   -L/usr/local/lib
 SENDMAIL_LDADD= -lsasl2 -lldap -llber

 sendmail -d0.1 -bt now includes LDAPMAP and USE_LDAP_INIT

Cool!  Just another useful bit, then, now that you got it all going.

Now you have to make sure you remember to rebuild Sendmail whenever
these libraries change version number.  An easy way to do this is using
something like:

% gothmog:/home/build/src# cat -n ../rebuild-sendmail.sh
%  1  #!/bin/sh
%  2
%  3  DIRS=
%  4  DIRS=${DIRS} ./bin/rmail
%  5  DIRS=${DIRS} ./lib/libmilter
%  6  DIRS=${DIRS} ./lib/libsm
%  7  DIRS=${DIRS} ./lib/libsmdb
%  8  DIRS=${DIRS} ./lib/libsmutil
%  9  DIRS=${DIRS} ./libexec/mail.local
% 10  DIRS=${DIRS} ./libexec/smrsh
% 11  DIRS=${DIRS} ./usr.bin/vacation
% 12  DIRS=${DIRS} ./usr.sbin/editmap
% 13  DIRS=${DIRS} ./usr.sbin/mailstats
% 14  DIRS=${DIRS} ./usr.sbin/makemap
% 15  DIRS=${DIRS} ./usr.sbin/praliases
% 16  DIRS=${DIRS} ./usr.sbin/sendmail
% 17
% 18  export MAKEOBJDIRPREFIX=/home/build/obj
% 19
% 20  for dname in ${DIRS} ; do
% 21  ( cd ${dname}  make clean  make  make install )
% 22  if test $? -ne 0 ; then
% 23  echo 
% 24  echo  FAILED while rebuilding ${dname}
% 25  exit 1
% 26  fi
% 27  done
% gothmog:/home/build/src#

I keep this script just one folder upwards of my usual build tree, and
then run it inside `/home/build/src' to rebuild the Sendmail bits.

Have fun,

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Boot manager beep (revisited)

2006-04-30 Thread Giorgos Keramidas
On 2006-04-30 21:36, Garrett Cooper [EMAIL PROTECTED] wrote:
Eric Anderson wrote:
 This thread:
 http://lists.freebsd.org/pipermail/freebsd-stable/2005-December/020572.html

 mentions a patch to disable the boot manager beep, and also discusses
 having it optional.  I don't have enough asm-fu to make that option
 happen, but I can tell you, that on laptops, that beep is really
 annoying, and amazingly loud.  Is this just waiting for an able minded
 person to code up the options and submit?

 Someone tell me how to use patch and I'll give it a shot. I sure as hell
 hate that stupid pc speaker beep notification.

My own patch to disable this is at:

http://people.freebsd.org/~keramida/diff/boot0_beep.diff

It should have a checksum of:

% md5 boot0_beep.diff ; sha1 boot0_beep.diff
MD5 (boot0_beep.diff) = edc1cdbdf6552c8f243ef7ec4fd9787a
SHA1 (boot0_beep.diff) = 1da96efff024282f5911871fe9f19ebd82628e24

You can fetch it with:

# cd /tmp
# fetch http://people.freebsd.org/~keramida/diff/boot0_beep.diff

Patching your source tree, since this patch has been generated from the
toplevel src/ tree should be as easy as:

# cd /usr/src
# patch -p0  /tmp/boot0_beep.diff

Then rebuild your boot0 block, and install the new boot0 file in /boot:

# cd /usr/src/sys/boot/i386/boot0
# make cleandir ; make cleandir
# make obj
# make all  make install

and update the MBR of your boot disk with boot0cfg, i.e.:

# boot0cfg -vB /dev/ad0

This should take care of it all.



pgpptdqNtIG9x.pgp
Description: PGP signature


Re: Sendmail Compile-Time Configuration

2006-04-28 Thread Giorgos Keramidas
On 2006-04-28 05:07, Duane Whitty [EMAIL PROTECTED] wrote:
Duane Whitty wrote:
Duane Whitty wrote:
 I'm adding LDAP support to my Sendmail configuration.  I couldn't seem
 to find the appropriate m4 file in which to declare my APPENDDEF
 statements.  My course of action was to include
 SENDMAIL_CFLAGS+=-DLDAPMAP in make.conf.  Does this seem like the
 correct way to do this for FreeBSD 6-STABLE?

That would be `/etc/make.conf'.

 Answering myself:

 I gues this isn't correct:

 /usr/src/lib/libmilter/../../contrib/sendmail/include/sm/config.h:148:20:
 lber.h: No such file or directory

 /usr/src/lib/libmilter/../../contrib/sendmail/include/sm/config.h:149:20:
 ldap.h: No such file or directory

 mkdep: compile failed
*** Error code 1

 I'll be continuing to work on this but hopefully someone
 here will have dealt with this previously

 Maybe SENDMAIL_ADDITIONAL_MC in make.conf will work
 with the needed APPENDDEF statements in my ldap.mc file?

No, you probably want something similar to the way SASL2 support is
compiled into the base-system version of Sendmail.  In my `make.conf'
I have the following:

SENDMAIL_CFLAGS=-I/usr/local/include -DSASL=2
SENDMAIL_LDFLAGS=   -L/usr/local/lib
SENDMAIL_LDADD= -lsasl2

While adding stuff to these variables please keep in mind that GCC on
FreeBSD has a major difference from the default GCC behavior: it does *not*
add /usr/local/include to the default include path or /usr/local/lib to the
default library search path.  So you will have to add them yourself, as
shown above.

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: procmail and sendmail

2006-04-28 Thread Giorgos Keramidas
On 2006-04-28 17:50, Efren Bravo [EMAIL PROTECTED] wrote:
 Hi,

 To store the users' mails on the server each one
 into separate file I've installed procmail v3.22
 from ports and unpacked it to add / to
 MAILSPOOLSUFFIX var inside /src/authenticate.c
 file and I rebuilt and installed it again.

 #ifndef MAILSPOOLSUFFIX
 #define MAILSPOOLSUFFIX /   /* suffix
 to force maildir or MH style */
 #endif

 but it doesn't work.

 What I missing?
 Some suggestion?

Is your Sendmail setup configured to use procmail for local email
delivery?  If not, you need to do that, and add your local system-wide
procmail options or filters to `/usr/local/etc/procmailrc'.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: procmail and sendmail

2006-04-28 Thread Giorgos Keramidas
On 2006-04-28 19:22, Efren Bravo [EMAIL PROTECTED] wrote:
 Giorgos Keramidas wrote:
  If not, you need to do that, and add your local system-wide procmail
  options or filters to `/usr/local/etc/procmailrc'.

 After installed the procmail, where can I find the procmailrc file
 because it's not into /usr/local/etc/ path ?

Nowhere, you create one yourself.  Very very carefully, because these
rules will be applied to *all* incoming local email.

The manpage of procmail(1) explains where Procmail will look for
filtering rules:

If  no rcfiles and no -p have been specified on the command line,
procmail will, prior to reading $HOME/.procmailrc, interpret
commands from /usr/local/etc/procmailrc (if present).  Care must be
taken when creating /usr/local/etc/procmailrc, because,  if
circumstances permit,  it will  be  executed  with  root privileges
(contrary to the $HOME/.procmailrc file of course).

For example, in your system-wide `procmailrc' file you can use rules
like the following:

MAILDIR=$HOME/Mail
DEFAULT=$HOME/Mailbox
LOGABSTRACT=no
LOGFILE=$HOME/procmail.log

:0 H
* ^X-Spam-Flag: YES
spam/.

:0 H
* ^Subject: {Spam not delivered}
spam/.

:0 H
* ^Subject: {Possible Spam}
spam/.

The /. suffix of the folder names means they are MH-style mail
folders.  You can also use a plain / suffix for Maildir folders,
or no suffix at all for plain Unix mbox-style files.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Simple firewall question: Blocking a handful of IPs

2006-04-27 Thread Giorgos Keramidas
On 2006-04-27 17:53, RW [EMAIL PROTECTED] wrote:
On Thursday 27 April 2006 03:10, fbsd wrote:
H. Wade Minter wrote:
 I want all traffic allowed unfettered, except traffic from
 particular IPs to be completely blocked coming in.

 Can someone show me which ipf rules to use to get that result?

   block in quick on rl0 from x.x.x.x  to any

 Unless the syntax is the same, that looks more like pf than ipf.

The syntax *is* the same, in this case.  The only ipf syntax
feature that ipf users are likely to miss from pf syntax is the
use of rule `groups', but this is not used here.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: scripting languages...

2006-04-27 Thread Giorgos Keramidas
On 2006-04-27 14:48, Gary Kline [EMAIL PROTECTED] wrote:
 On Thu, Apr 27, 2006 at 06:10:43AM +0300, Giorgos Keramidas wrote:
  Don't you really mean ``C#'' by writing ``ch''?

 The only thing I recall reading about C# is that it was
 a DOS/Win C++ ish language.  ch is a C/C++ scripting language
 that is like /bin/sh only with C syntax.Some C wizards
 created a perl regex library for ch; thus my question.

I've never heard of `ch'.  I know what `C#' is, what `csh' is, what
`sh', `ksh', `zsh' and several other shells are.  I don't know what `ch'
is though :-/

 The fact that perl is everywhere is in its favor; perl
 gurus can deal with argc/argv in their *sleep*.  I can't;
 but it might interest you that many years ago I ported
 perl from the Sun-3 to an IBM AIX 3090 (with all 6 CPU's).
 Worked fine.

HEH!  That must have been fun :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: scripting languages...

2006-04-27 Thread Giorgos Keramidas
On 2006-04-27 16:58, Gary Kline [EMAIL PROTECTED] wrote:
  Getting at argv/argc is actually pretty simple in Perl. The global array
  @ARGV contains the arguments given on the command-line, but not the name
  of the file (this datum is contained in $0). Therefore your argv[1] in C
  is $ARGV[0] in Perl. The number of command-line arguments can be
  obtained in two ways, either you interpret the array in a scalar context
  and get its length: ``my $argc = scalar @ARGV'' or you use the last
  index of the array and add one: ``my $argc = $#ARGV + 1''. Of course, in
  most cases you'll just want to loop over the command-line args, so a
  foreach loop should suffice, or of course one of the Getopt (Getopt::Std
  or Getopt::Long in most cases) modules.
 
   So, could I say:
 
   my $argc = $#ARGV+1; $count = 0;
   while ($argc--)
   {
   if (! (checkErr($ARGV[$count], $count)))
   {
   printf(Processing %s\n, $ARGV[$count]);
   doWhatever($ARGV[$count]);
   }
   $count++;
   }
 
   or something close-to!?

I believe the idiomatic way of doing this would be something more like:

foreach $arg (@ARGV) {
if (!checkErr($arg)) {
printf(Processing %s\n, $arg);
doWhatever($arg);
}
}

Your version may work too, but I'm always wary of all the index
trickery involved in handling $#ARGV fearing it may easily lead to
off-by-one bugs.  So I prefer foreach() loops :)


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: shadow.h compile question

2006-04-27 Thread Giorgos Keramidas
On 2006-04-27 17:24, Sean Murphy [EMAIL PROTECTED] wrote:
 I am trying to compile a plugin for squrrilmail it is the vacation
 plugin.  when I run make it tells me the it cannot find shadow.h

 I did a find on the freebsd server which is 5.4 and did not find
 shadow or shadow.h

 what is shadow.h?  can I get it from anywhere?

A Linuxism that has been used by the author of the software:

$ find /usr/include -name shadow.h
/usr/include/shadow.h
$ uname -a
Linux foo 2.6.10 #1 Thu Dec 30 03:01:16 EET 2004 i686 GNU/Linux
$

User programs shouldn't depend on shadow.h but use the pwd.h
header instead and the getpwent() library function, whenever they need
to access user/password information.

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Take us off this list please

2006-04-26 Thread Giorgos Keramidas
On 2006-04-26 07:30, Ingrid Kast Fuller [EMAIL PROTECTED] wrote:
 Please take CityScope Net off this Japanese list. We only want to be on
 English reading websites. (USA/England/Australia)
 Thanks.

 www.it.freebsd.org/ja/gallery/cgallery.html

Hi,

I've forwarded your request to ``freebsd-www'', which is the place our
web developers hang out.  You should, normally, hear back from one of
our Japanese web gurus :-)

Regards,
Giorgos



pgpdaLOX12qpg.pgp
Description: PGP signature


Re: sendmail_enable in rc.conf

2006-04-26 Thread Giorgos Keramidas
On 2006-04-27 06:41, [EMAIL PROTECTED] wrote:
 I have FreeBSD 6.0-RELEASE.
 It seems there is collision between /etc/defaults/rc.conf and
 /etc/rc.sendmail in sendmail startup control.
 In /etc/defaults/rc.conf:
 sendmail_enable=NO# Run the sendmail inbound daemon (YES/NO).
 In /etc/rc.sendmail:
 ...
 start_mta()
 {
 case ${sendmail_enable} in
 [Nn][Oo][Nn][Ee])
 ;;
 

 So sendmail doesn't startup during system startup only if there is
 sendmail_enable=NONE in /etc/rc.conf.

True.

 Maybe I don't understand something?

Yes, you are missing something.  The `sendmail_enable' variable is
overloaded for two different purposes, which do not necessarily conflict
with each other.

sendmail_enable=NO
This disables _only_ the ``inbound Sendmail daemon''.

sendmail_enable=NONE
This value disables _all_ Sendmail daemons.

The fine difference here is that in recent Sendmail versions, Sendmail
can run one or more daemons for:

- Receiving email messages from local programs.  This is the
  submission daemon, listening by default only to port 127.0.0.1:25.

  The fine-grained tunable for this daemon is `sendmail_submit_enable'.

- Handing off locally submitted messages from the `submit' queue to
  a mail relay server (`SMART_HOST' in Sendmail's language).  This
  is very useful when combined with `sendmail_submit_enable' if you
  are not running a publicly visible mail server.  You can use the
  `submit' daemon as a queueing mechanism for locally sent email and
  periodically flush its queue, sending all outgoing messages on
  their way out with the Sendmail MSP queue runner.

  The tunable for the MSP queue runner is `sendmail_msp_queue_enable'.

  | NOTE: With these two options (`sendmail_submit_enable' and its
  | companion, `sendmail_msp_queue_enable') in mind, my usual
  | `rc.conf' options for workstation machines, that mostly send
  | local email to local users and forward everything else through a
  | SMART_HOST to the world, are:
  |
  | sendmail_enable=NO
  | sendmail_outbound_enable=NO
  | sendmail_submit_enable=YES
  | sendmail_msp_queue_enable=YES
  |
  | This, and a proper `SMART_HOST' in my `/etc/mail/sendmail.mc'
  | file, are all it takes to have email flowing out of a simple
  | workstation system.

- On a publicly visible mail server (i.e. one that hosts email for
  one or more domains that are visible on the wide Internet), you
  will almost certainly need to use sendmail_enable=YES too, to
  make sure a Sendmail daemon listens on all the non-localhost
  interfaces.

- The fourth option, `sendmail_outbound_enable', is something you
  will probably never need with Sendmail.  Don't worry about it yet.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: scripting languages...

2006-04-26 Thread Giorgos Keramidas
On 2006-04-26 19:41, Gary Kline [EMAIL PROTECTED] wrote:

 Hi People,
 I am NOT trying to start any kind of flame debate, but would
 like to know what real advantage perl has over the newer
 so-called all-in-one language, ch.   (Other than the obvious
 fact that there are literally billions of lines of perl existant.)

Don't you really mean ``C#'' by writing ``ch''?

Perl seems ubiquitous these days.  Every operating system I regularly
have to use (Linux, BSD or Solaris, in my case) has a Perl
implementation that works the same way 90% of the time.  When it
doesn't, there's almost certainly a CPAN module that does the trick.

$ uname -v
FreeBSD 7.0-CURRENT #0: Thu Apr 20 06:26:59 EEST 2006 \
[EMAIL PROTECTED]:/home/build/obj/home/build/src/sys/GOTHMOG
$ perl --version | grep '^This'
This is perl, v5.8.8 built for i386-freebsd-64int

$ uname -a
SunOS  5.10 Generic_118844-28 i86pc i386 i86pc
$ perl --version | grep '^This'
This is perl, v5.8.4 built for i86pc-solaris-64int

$ uname -a
SunOS  5.10 Generic_118822-27 sun4u sparc SUNW,Sun-Fire-V240
$ perl --version | grep '^This'
This is perl, v5.8.4 built for sun4-solaris-64int

$ uname -a
Linux  2.4.26 #1 SMP Thu May 6 23:04:59 EEST 2004 i686 GNU/Linux
$ perl --version | grep '^This'
This is perl, v5.8.8 built for i486-linux-gnu-thread-multi

$ uname -a
Linux  2.6.10 #1 Thu Dec 30 03:01:16 EET 2004 i686 GNU/Linux
$ perl --version | grep '^This'
This is perl, v5.8.8 built for i486-linux-gnu-thread-multi

The biggest advantage of Perl for me right now is that ``A Fairly Modern
Version is Just There(TM)'', wherever I have to work :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: custom kernel file question

2006-04-20 Thread Giorgos Keramidas
On 2006-04-20 14:01, Jonathan Horne [EMAIL PROTECTED] wrote:
 here is a silly one, which may deserve a chuckle from my peers :)

 what am i doing that zaps my custom kernel config file?  i compiled a new
 one the day i built this box, but now i return to /usr/src/sys/i386/conf/,
 and my file isnt there anymore!

You run CVSup with the `*default delete' option enabled in your supfile.

 what did i do that removed it, so i can avoid (or safeguard against) this
 action in the future?

Keep your kernel config outside the /usr/src/sys/i386/conf tree and
symlink to it every time you build.

# cd /usr/src/sys/i386/conf
# ln -s /root/kernconf/GIORGOS
# cd /usr/src
# make KERNCONF=GIORGOS buildworld buildkernel

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Installing Free over linux

2006-04-19 Thread Giorgos Keramidas
On Tuesday, April 18, 2006 1:00 PM Aguiar Magalhaes wrote:
 I'm trying to install the FreeBSD 6.0 where exist a
 old linux (It will be full replaced)

 I'm receiving a error message about de swap slice:

 Unable to find device node for /dev/ad0s1b in /dev!
 The creation of filesystem will be aborted

On 2006-04-19 14:02, Aguiar Magalhaes [EMAIL PROTECTED] wrote:
 Hi Parv,
 I'm trying but the same error message is continue

Try doing this in two runs of sysinstall:

* Create the BIOS partitions without any BSD label
* Save the partitions and reboot
* Then create the BSD label and swap

I vaguely remember sysinstall having problems with partitions that were
created in one session, but I haven't used sysinstall in ages now...

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Help

2006-04-19 Thread Giorgos Keramidas
On 2006-04-19 21:33, Deepak Venkatesan [EMAIL PROTECTED] wrote:
 I wish to use softwares of Adobe, Nero, Microsoft,etc. Can you send me
 the softwares that support FreeBSD OS.

Hi Deepak,

I'm almost positively sure that you are looking at the wrong list.

FreeBSD is a UNIX system (see the description at its homepage, at
http://www.FreeBSD.org for example).  While *some* of the software
vendors you listed above (i.e. Adobe) make *some* versions of their
software available for *some* UNIX systems, I don't think it is a very
common or widespread practice for large, commercial software vendors to
ship FreeBSD versions of their software.

Having said that, FreeBSD can run and does support thousands of Free
Software and Open Source Software packages.  Perhaps you can tell us
what you are trying to do, and we can find some FS/OSS program that can
assist you?

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: postfix smtp_sasl_auth

2006-04-19 Thread Giorgos Keramidas
On 2006-04-19 15:35, Alan Curtis [EMAIL PROTECTED] wrote:
 I had postfix set up to use  smtp_sasl_auth for outgoing mail. But now
 it's broken and I get this message in maillog.

 Apr 19 15:11:23  postfix/smtp[17464]: warning:
 smtp_sasl_auth_enable is true, but SASL support is not compiled in
 Apr 19 15:11:23  postfix/smtp[17464]: warning: TLS has been
 selected, but TLS support is not compiled in

 I think I must have broken something during a port upgrade. How do I fix this?

Remove /usr/ports/mail/postfix/Makefile.inc and rebuild postfix.  You
will be prompted for configuration options again.  You seem to have TLS
and SASL in your `main.cf' file but forgot to include them in the latest
build.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: postfix smtp_sasl_auth

2006-04-19 Thread Giorgos Keramidas
On 2006-04-19 14:49, Zimmerman, Eric [EMAIL PROTECTED] wrote:
 Giorgos Keramidas wrote:
  Remove /usr/ports/mail/postfix/Makefile.inc and rebuild
  postfix.  You will be prompted for configuration options
  again.  You seem to have TLS and SASL in your `main.cf' file
  but forgot to include them in the latest build.

 I think you can do a 'make config' as well in the port
 directory to reconfigure

Very cool.  I didn't know that :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: /boot at beginning of drive

2006-04-18 Thread Giorgos Keramidas
On 2006-04-17 17:18, David J Brooks [EMAIL PROTECTED] wrote:
  http://users.rcn.com/rneswold/fbsd-init.html#AEN258

 I stand corrected. I can still envision problems if tmp files use enough space
 to prevent a memory swap. Running out of swap space is not healthy.

That's why swap-backed /tmp filesystems have a `size'.  To make sure
they can't exceed it :)

If, knowing all this, you still plan for a very small swap space, then
you are right that problems will start creeping up very fast.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


RE: /boot at beginning of drive

2006-04-17 Thread Giorgos Keramidas

On 2006-04-17 06:21, Brendan Grossman wrote:

Beech Rintoul [mailto:[EMAIL PROTECTED] wrote:

On Sunday 16 April 2006 12:38, Brendan Grossman wrote:

It's not a good idea to put everything on the / filesystem.
At a minimum I would have:
/
swap
/var
/usr

Your users will not fill up /var unless you allow them unlimited
mail, databases or access to root.


They will have unlimited access up until their quota has

been reached.

Where they use that quota is anyone's guess.


User's tempfiles will go to /usr/tmp.


How does that work? I just checked /tmp, and it's not a symlink.


Copy the contents of /tmp to /usr/tmp then remove /tmp and
symlink /usr/tmp to /tmp.


Yes, may I ask what the point is though?

Here is my reason for separating /tmp and mounting it noexec,nosuid:

http://www.sagonet.com/forums/showthread.php?t=2852


You should also take a look at the following rc.conf options then:

tmpmfs=AUTO   # Set to YES to always create an mfs /tmp, NO to 
never
tmpsize=20m   # Size of mfs /tmp if created
tmpmfs_flags=-S -M# Extra mdmfs options for the mfs /tmp

If you have enough swap space, there's no need to worry too much about
making a separate /tmp partition.  Just set:

tmpmfs=YES
tmpsize=100m
tmpmfs_flags=-S -M -o noexec,nosuid

Note the -o option in `tmpmfs_flags'.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: make buildword problem/documentation

2006-04-12 Thread Giorgos Keramidas
On 2006-04-11 21:10, Giorgos Keramidas [EMAIL PROTECTED] wrote:
 On 2006-04-11 17:50, Jim Stapleton [EMAIL PROTECTED] wrote:
  ahh, thanks everyone, I was looking through the document, and focused
  on finding buildworld.
 
  Still, anyone know why those particular cflags would cause problems?

 Don't use arbitrary CFLAGS in `make.conf'.  The build is already
 complicated enough and careful steps have to be taken, without the
 introduction of random flags.

On 2006-04-11 18:27, Jim Stapleton [EMAIL PROTECTED] wrote:
 ok, thanks, I won't worry about it then.

Cool.

 I just like to have everything as optimised as possible. Guess it'll
 have to wait here...

There are cases when things break in one or another way if you enable
optimizations for all the builds, in make.conf.  The warning near the
description of CFLAGS in `/usr/share/examples/etc/make.conf' is there
exactly to avoid this sort of thing:

# Note that optimization settings other than -O and -O2 are not recommended
# or supported for compiling the world or the kernel - please revert any
# nonstandard optimization settings to -O or -O2 before submitting bug
# reports without patches to the developers.

So, unless there is a measurable performance gain which doesn't also
result in strange build- or runtime errors, I guess you don't need to
worry about it too much :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: pow function working unexpectedly

2006-04-12 Thread Giorgos Keramidas
On 2006-04-11 22:54, Jonathan Herriott [EMAIL PROTECTED] wrote:
 I just want to make sure I'm not being stupid before I send in a bug.
 The problem seems to be with gcc when using the pow function in the
 math.h library.  Here's code that works:

 #include stdio.h
 #include math.h

 int main()
 {
  printf(%f\n, pow(2,3));
  return 0;
 }


 Now, the following will not compile:

 #include stdio.h
 #include math.h

 int main()
 {
  int x = 2; // I tried these as doubles too since the pow function
 takes doubles
  int y = 3;

  printf(%f\n, pow(x,y));
  return 0;
 }

 I compiled both programs using:
 gcc test.c

 The second example gives the following error:
 /var/tmp//ccxtkMwv.o(.text+0x45): In function `main':
 : undefined reference to `pow'

There are two things at work here that are a bit confusing.  In the
first case, the arguments of pow() are constants, so the compiler knows
the result of the pow() call at compile-time.  GCC tries to optimize
this call away by replacing the entire pow() call with the literal
result.  You can see this by:

# $ cat -n pow1.c
#  1  #include stdio.h
#  2  #include math.h
#  3
#  4  int
#  5  main(void)
#  6  {
#  7
#  8  printf(%f\n, pow(2,3));
#  9  return 0;
# 10  }

If you compile this program to assembler, there is no call to pow():

# $ gcc -std=c99 -pedantic -O2 -S pow1.c
# $ cat -n pow1.s
#  1  .file   pow1.c
#  2  .section.rodata.str1.1,aMS,@progbits,1
#  3  .LC1:
#  4  .string %f\n
#  5  .text
#  6  .p2align 2,,3
#  7  .globl main
#  8  .type   main, @function
#  9  main:
# 10  pushl   %ebp
# 11  movl%esp, %ebp
# 12  subl$8, %esp
# 13  andl$-16, %esp
# 14  subl$20, %esp
# 15  pushl   $1075838976
# 16  pushl   $0
# 17  pushl   $.LC1
# 18  callprintf
# 19  xorl%eax, %eax
# 20  leave
# 21  ret
# 22  .size   main, .-main
# 23  .ident  GCC: (GNU) 3.4.4 [FreeBSD] 20050518
# $

Lines 15-17 are pushing the arguments of printf() on the stack, so
obviously GCC has pre-calculated the value of pow(2,3) for us.

With the second program, which uses variables for storing the values
passed to pow(), GCC cannot use the same trick, as the *values* of the
variables are only known at runtime.  This way, this program:

# $ cat -n pow2.c
#  1  #include stdio.h
#  2  #include math.h
#  3
#  4  int
#  5  main(void)
#  6  {
#  7  int x = 2; /* I tried these as doubles too since the pow 
function takes doubles */
#  8  int y = 3;
#  9
# 10  printf(%f\n, pow(x,y));
# 11  return 0;
# 12  }
# $

Compiles to slightly different object code:

# $ gcc -std=c99 -pedantic -O2 -S pow2.c
# $ cat -n pow2.s
#  1  .file   pow2.c
#  2  .section.rodata.str1.1,aMS,@progbits,1
#  3  .LC0:
#  4  .string %f\n
#  5  .text
#  6  .p2align 2,,3
#  7  .globl main
#  8  .type   main, @function
#  9  main:
# 10  pushl   %ebp
# 11  movl%esp, %ebp
# 12  subl$8, %esp
# 13  andl$-16, %esp
# 14  subl$32, %esp
# 15  pushl   $1074266112
# 16  pushl   $0
# 17  pushl   $1073741824
# 18  pushl   $0
# 19  callpow
# 20  addl$20, %esp
# 21  fstpl   (%esp)
# 22  pushl   $.LC0
# 23  callprintf
# 24  xorl%eax, %eax
# 25  leave
# 26  ret
# 27  .size   main, .-main
# 28  .ident  GCC: (GNU) 3.4.4 [FreeBSD] 20050518

Here a call to pow() is used, so the second program uncovers the fact
that you need the -lm math library to work with math functions, which is
why GCC complains about an undefined reference to pow().

 If I comile with g++, I have no issues.  Are these results that I
 should have?  If so, why?  If not, I'm going to submit the bug on gcc
 (or the linker, but I'm guessing it's the same group).

This is not a C++ program, so you should use a C compiler for it :)

Regards,
Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Forcing build of vulnerable port

2006-04-12 Thread Giorgos Keramidas
On 2006-04-12 18:17, Erik Norgaard [EMAIL PROTECTED] wrote:
 Hi:

 I am working with java card and it seems that I need to use jdk12, to
 install that I need jdk11, which fails because of a reported vulnerability.

 How do I force building a vulnerable port?

I think you can still install vulnerable ports, with:

env DISABLE_VULNERABILITIES=yes make install

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: make buildword problem/documentation

2006-04-11 Thread Giorgos Keramidas
On 2006-04-11 17:50, Jim Stapleton [EMAIL PROTECTED] wrote:
 ahh, thanks everyone, I was looking through the document, and focused
 on finding buildworld.

 Still, anyone know why those particular cflags would cause problems?

Don't use arbitrary CFLAGS in `make.conf'.  The build is already
complicated enough and careful steps have to be taken, without the
introduction of random flags.

You'd have to show us the particular errors you are seeing (possibly a
*FULL* transcript of the build) before we can answer why these
particular flags fail and how.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


<    5   6   7   8   9   10   11   12   13   14   >