Re: had sound working, updated machine now lost sound

2013-08-26 Thread Carl Johnson
Antonio Olivares olivares14...@gmail.com writes:

 Dear all,

 Following  advice from  thread(s) :

 http://forums.pcbsd.org/showthread.php?t=13976

 http://forums.freebsd.org/showthread.php?t=5136

 root@grullahighschool:~ # sysctl hw.snd.default_unit=0
 hw.snd.default_unit: 1 - 0

 Got the sound working like it was.
 How do I get it to stick across reboots?

 Which would be the preferred way?

Since you can set it with sysctl then sysctl.conf is the logical place,
although loader.conf might also work.  I use sysctl.conf so I know that
works.

-- 
Carl Johnsonca...@peak.org
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: gvim GUI cannot be used

2013-07-05 Thread Carl Johnson
Jens Jahnke jan0...@gmx.net writes:

 Hi,

 On Fri, 5 Jul 2013 12:56:32 +0200
 CeDeROM cede...@tlen.pl wrote:

 C Hey Raphael :-) Go to /usr/ports/editors/vim and make deinstall
 C reinstall it, that works for me, and it helps with dialogs in texmode
 C as well :-)

 for me this does not work. Unless I hack the Makefile and force it to
 enable gui mode it just isn't compiled in.

Try running 'make show-options' and see what you get.  Mine shows that
virtually everything is disabled.  If I run 'make showconfig' then it
shows no configurable options.

-- 
Carl Johnsonca...@peak.org
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: define more partitions in freebsd

2013-06-02 Thread Carl Johnson
s m sam.gh1...@gmail.com writes:

 thanks guys,

 i understand another solution is GPT partitioning. but i prefer to have
 more partitions in traditional freebsd (with MBR table i think). using GPT
 is the last solution for me.

 i should create more than 8 partitions with gpart command (flag n which
 identifies entries) but i have errors when using it. is there any special
 option which should be included in kernel in order to use gpart with flag
 n? any one test it before?

 thanks in advance,

I just tried it on a FreeBSD 8.3 system without any problems.  You will
need to explain what kind of errors you had before anybody can help you.
I used a zfs volume for testing as follows:

gpart create -s MBR /dev/zvol/zpool/v/gtest
gpart add -t freebsd /dev/zvol/zpool/v/gtest
gpart create -s BSD -n 20 zvol/zpool/v/gtests1
gpart add -t freebsd-ufs -s 1G zvol/zpool/v/gtests1
gpart add -t freebsd-swap -s 2G zvol/zpool/v/gtests1
# add several more freebsd-ufs
# output from 'gpart show zvol/zpool/v/gtests1'
=   0  41942943  zvol/zpool/v/gtests1  BSD  (20G)
 0   2097152 1  freebsd-ufs  (1.0G)
   2097152   4194304 2  freebsd-swap  (2.0G)
   6291456   2097152 4  freebsd-ufs  (1.0G)
   8388608   2097152 5  freebsd-ufs  (1.0G)
  10485760   2097152 6  freebsd-ufs  (1.0G)
  12582912   2097152 7  freebsd-ufs  (1.0G)
  14680064   2097152 8  freebsd-ufs  (1.0G)
  16777216   2097152 9  freebsd-ufs  (1.0G)
  18874368   209715210  freebsd-ufs  (1.0G)
  20971520   209715211  freebsd-ufs  (1.0G)
  23068672   209715212  freebsd-ufs  (1.0G)
  25165824   209715213  freebsd-ufs  (1.0G)
  27262976   209715214  freebsd-ufs  (1.0G)
  29360128   209715215  freebsd-ufs  (1.0G)
  31457280   209715216  freebsd-ufs  (1.0G)
  33554432   209715217  freebsd-ufs  (1.0G)
  35651584   209715218  freebsd-ufs  (1.0G)
  37748736   209715219  freebsd-ufs  (1.0G)
  39845888   209705520  freebsd-ufs  (1G)
# output from 'disklabel zvol/zpool/v/gtests1'
# /dev/zvol/zpool/v/gtests1:
20 partitions:
#  size offsetfstype   [fsize bsize bps/cpg]
  a:2097152  04.2BSD0 0 0
  b:41943042097152  swap
  c:   41942943  0unused0 0 # raw part, don't edit
  d:209715262914564.2BSD0 0 0
  e:209715283886084.2BSD0 0 0
  f:2097152   104857604.2BSD0 0 0
  g:2097152   125829124.2BSD0 0 0
  h:2097152   146800644.2BSD0 0 0
  i:2097152   167772164.2BSD0 0 0
  j:2097152   188743684.2BSD0 0 0
  k:2097152   209715204.2BSD0 0 0
  l:2097152   230686724.2BSD0 0 0
  m:2097152   251658244.2BSD0 0 0
  n:2097152   272629764.2BSD0 0 0
  o:2097152   293601284.2BSD0 0 0
  p:2097152   314572804.2BSD0 0 0
  q:2097152   335544324.2BSD0 0 0
  r:2097152   356515844.2BSD0 0 0
  s:2097152   377487364.2BSD0 0 0
  t:2097055   398458884.2BSD0 0 0

I also tried newfs on all the ufs partitions without problems.  I just
tried this on a FreeBSD 8.2 system and it works there as well.

-- 
Carl Johnsonca...@peak.org
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: define more partitions in freebsd

2013-06-01 Thread Carl Johnson
s m sam.gh1...@gmail.com writes:

 hello all

 i want to install freebsd8.2 on my system. for some reasons, i need
 partitions more than 6. my freebsd just allow me to define partitions
 from a to h, not any more.

 i checked FreeBSD handbook, but it doesn't say anything about defining
 more partitions.

 my question is: how can i define more partitions on my freebsd? (for
 example, ad3s1a, ..., ad3s1h, ad3s1i, ad3s1j, ...).

 any comments or hints are appreciated.
 SAM

Others have already commented that GPT labels are better, but I think
that you can have more than 8 partitions.  I remember a posting a while
back that the maximum had been increased.  You will have to experiment
if you want to do this, but gpart shows an example that uses 20
partitions:  '/sbin/gpart create -s BSD -n 20 ada0s1'.  I also don't
know that bsdlabel will handle these, so you definitely should
experiment first.
-- 
Carl Johnsonca...@peak.org
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Recipie for CPU souffle'

2013-04-03 Thread Carl Johnson
Polytropon free...@edvax.de writes:

 On Tue, 02 Apr 2013 12:55:20 -0700, Ronald F. Guilmette wrote:

 No, that does not work. Read the manpage to recognize clearly
 _what_ kind of input the /dev/speaker device accepts. It does
 not understand WAV files.

 However, try this example (cw.sh):

 #!/bin/sh

 read -p CW ===  TEXT
 echo ${TEXT} | morse | awk '{
   if(length($0) == 0)
   printf(P4\n);
   else {
   gsub( dit, P32L32E, $0);
   gsub( di,  P32L32E, $0);
   gsub( dah, P32L8E,  $0);
   printf(%sP16\n, $0);
   }
 }' | dd bs=256 of=/dev/speaker  /dev/null 21

 This script doesn't require any non-OS components. You can use
 it as a basis to build a program that will send you system messages
 in an audible way in morse code... :-)

Have you looked at the morse man page lately, specifically the -p
option? :-)  Just try 'morse -p sos' to test it.

-- 
Carl Johnsonca...@peak.org
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: FreeBSD 9 and Windows XP

2013-03-11 Thread Carl Johnson
Eduardo Morras emorr...@yahoo.es writes:

 On Sat,  9 Mar 2013 12:07:41 -0800 (PST)
 leeoliveshackelf...@surewest.net wrote:

 Good afternoon, FreeBSD enthusiasts.  Can FreeBSD 9.1 be installed on
 a computer on which Windows XP currently resides?  If so, how can
 this installation be done?  In particular, is there a way to install
 9.1 so that it can be booted from the traditional master boot record?
 It is important that, when I am done, I can still boot to Windows
 XP, as I must run some applications not available on FreeBSD.  If the
 idea I am proposing is not feasible with version 9.1, will it work
 with 8.3?  Any comments are appreciated.  If this question has
 already been asked many times before, please just let me know where
 to look to find the answer.  Thanks.  Newbie502


 As an addon to other answers, you can install VirtualBox, create a
 minimal hard disk with MBR boot menu that points to the WindowsXP
 partition. This way you don't need to restart in WinXP. The same can
 be done from WinXP side, a minimal hd with MBR boot menu to startup
 the FreeBSD.

It is my understanding that FreeBSD doesn't allow using part of a disk,
but grabs the entire disk.  That means that VirtualBox can't use
partitions on a disk that any other partitions are being used by
anything else, including FreeBSD itself.  Am I wrong about this?  I use
VirtualBox using vdmk for an entire disk, but I have never been able to
share with anything else.
-- 
Carl Johnsonca...@peak.org
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: FreeBSD 9 and Windows XP

2013-03-11 Thread Carl Johnson
Warren Block wbl...@wonkity.com writes:

 On Mon, 11 Mar 2013, Carl Johnson wrote:

 It is my understanding that FreeBSD doesn't allow using part of a disk,
 but grabs the entire disk.  That means that VirtualBox can't use
 partitions on a disk that any other partitions are being used by
 anything else, including FreeBSD itself.  Am I wrong about this?  I use
 VirtualBox using vdmk for an entire disk, but I have never been able to
 share with anything else.

 It's very hard to tell what situation is being described here.  If the
 VMDK is a pointer to a whole physical disk, that would probably make
 the disk only usable by one VM.  It should be possible to make the
 VMDK point to just one partition on the disk.  Then other VMs or a
 physical machine could use those other partitions while the FreeBSD VM
 was running.

I was thinking of the case where I tried to allow direct access by a
virtual machine to a slice on the same disk that I was running FreeBSD
off of.  I just looked further into that and discovered that it is
possible, but not allowed by geom by default.  It can be done by setting
'sysctl kern.geom.debugflags=0x10'.  I am sure that you are aware of the
dangers, but for anybody else reading this check out the warning in the
geom(4) manpage.  They refer to this option as 'allow foot shooting' for
a reason.

-- 
Carl Johnsonca...@peak.org
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


freebsd-update problems

2013-02-01 Thread Carl Johnson
I ran freebsd-update to update my 8.1-RELEASE system to 8.3-RELEASE
(freebsd-update -r 8.3-RELEASE upgrade).  It downloaded a bunch of
files, asked me to edit some configuration files, showed me long lists
of files that have been changed, added and removed, and then ended with
no status or error indications.  The problem is that there appears to be
absolutely NO change in my system that I can find.  I have checked /etc,
/bin, and /lib with 'ls -lct | head', but there are no files that have
changed recently.  The /var/db/freebsd-update directory has over 500MB
of files it downloaded.

Does anybody have any suggestions on what might have happened and what
can be done?
-- 
Carl Johnsonca...@peak.org

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


Re: freebsd-update problems

2013-02-01 Thread Carl Johnson
Kevin Kinsey k...@daleco.biz writes:

 On Fri, Feb 01, 2013 at 11:51:41AM -0800, Carl Johnson wrote:
 I ran freebsd-update to update my 8.1-RELEASE system to 8.3-RELEASE
 (freebsd-update -r 8.3-RELEASE upgrade).  It downloaded a bunch of
 files, asked me to edit some configuration files, showed me long lists
 of files that have been changed, added and removed, and then ended with
 no status or error indications.  The problem is that there appears to be
 absolutely NO change in my system that I can find.  I have checked /etc,
 /bin, and /lib with 'ls -lct | head', but there are no files that have
 changed recently.  The /var/db/freebsd-update directory has over 500MB
 of files it downloaded.
 
 Does anybody have any suggestions on what might have happened and what
 can be done?
 -- 
 Carl Johnson ca...@peak.org
 

 I'm not looking at the docs ATM, but IIRC you need to run an install
 step now.  Check the docs ... they should tell you.

Thanks, I just saw that a few minutes ago.  I wasn't happy about it so I
went out for a long walk, but I should have done it before posting.
I'll try that right after this.

-- 
Carl Johnsonca...@peak.org

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


Re: freebsd-update problems

2013-02-01 Thread Carl Johnson
Gökşin Akdeniz goksin.akde...@gmail.com writes:

 Fri, 01 Feb 2013 11:51:41 -0800 tarihinde
 Carl Johnson ca...@peak.org yazmış:
 
 Does anybody have any suggestions on what might have happened and what
 can be done?
 

 Hello Carl,

 What does # uname -a or # uname -r output says?

It still shows 8.1, but another poster just pointed out that I hadn't
installed my upgrade.  I need to read the man pages more carefully.
Thanks.

-- 
Carl Johnsonca...@peak.org

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

Re: freebsd-update problems

2013-02-01 Thread Carl Johnson
Carl Johnson ca...@peak.org writes:

 Kevin Kinsey k...@daleco.biz writes:

 On Fri, Feb 01, 2013 at 11:51:41AM -0800, Carl Johnson wrote:
 I ran freebsd-update to update my 8.1-RELEASE system to 8.3-RELEASE
 (freebsd-update -r 8.3-RELEASE upgrade).  It downloaded a bunch of
 files, asked me to edit some configuration files, showed me long lists
 of files that have been changed, added and removed, and then ended with
 no status or error indications.  The problem is that there appears to be
 absolutely NO change in my system that I can find.  I have checked /etc,
 /bin, and /lib with 'ls -lct | head', but there are no files that have
 changed recently.  The /var/db/freebsd-update directory has over 500MB
 of files it downloaded.
 
 Does anybody have any suggestions on what might have happened and what
 can be done?
 -- 
 Carl Johnsonca...@peak.org
 

 I'm not looking at the docs ATM, but IIRC you need to run an install
 step now.  Check the docs ... they should tell you.

 Thanks, I just saw that a few minutes ago.  I wasn't happy about it so I
 went out for a long walk, but I should have done it before posting.
 I'll try that right after this.

Everything looks good now:  'uname -r' now show '8.3-RELEASE-p3'.
Thanks for the response.

-- 
Carl Johnsonca...@peak.org

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


Re: freebsd-update problems

2013-02-01 Thread Carl Johnson
Paul Macdonald p...@ifdnrg.com writes:

 On 01/02/2013 22:50, Carl Johnson wrote:
 Gökşin Akdeniz goksin.akde...@gmail.com writes:

 Fri, 01 Feb 2013 11:51:41 -0800 tarihinde
 Carl Johnson ca...@peak.org yazmış:
 Does anybody have any suggestions on what might have happened and what
 can be done?

 Hello Carl,

 What does # uname -a or # uname -r output says?
 It still shows 8.1, but another poster just pointed out that I hadn't
 installed my upgrade.  I need to read the man pages more carefully.
 Thanks.


 Better link:
 http://www.freebsd.org/doc/handbook/updating-upgrading-freebsdupdate.html#freebsdupdate-using

Thanks, that link is much clearer than the version of the handbook that
came with my 8.1 system.

-- 
Carl Johnsonca...@peak.org

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

Re: Mount Logical (ext2fs) Partitions?

2013-01-26 Thread Carl Johnson
Walter Hurry walterhu...@gmail.com writes:

 On Fri, 25 Jan 2013 21:07:59 -0800, Carl Johnson wrote:

 There is a package called 'linuxfdisk' that is just a FreeBSD
 implementation of the linux fdisk and will show you what the FreeBSD
 partitions/slices are.  You can also use gpart in the base system to get
 the same information.  The command 'gpart list ada0' will show the
 primary partitions, and the command 'gpart list ada0s4' should show the
 logical partitions inside of the extended partition.  You can also use
 'file -s' and possibly do read-only mounts to see exactly what they
 contain.  The names will probably map out like linux, but the 'sda*'
 will be changed to 'ada0s*'.

 Thanks for the pointers. Here is the relevant part of the output from 
 'gpart list ada0s4':

 4. Name: ada0s8
Mediasize: 4194304 (39G)
Sectorsize: 512
Stripesize: 0
Stripeoffset: 162529280
Mode: r0w0e0
rawtype: 131
length: 4194304
offset: 46143188992
type: linux-data
index: 1430498
end: 172043415
start: 90121368

 So I put into my /etc/fstab:

 /dev/ada0s8 /u01ext2fs  ro,noauto 00

 But when I issue 'sudo mount /u01' I get:

 mount: /dev/ada0s8: Invalid argument


 What am I doing wrong?

I don't see anything wrong there.  I use labels when possible, but that
doesn't really change anything.  Have you tried using 'file -s
/dev/ada0s8' to see what the kernel thinks it is?
-- 
Carl Johnsonca...@peak.org

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


Re: Mount Logical (ext2fs) Partitions?

2013-01-26 Thread Carl Johnson
Walter Hurry walterhu...@gmail.com writes:

 So it's my stupid mistake. I could have sworn it was ext2, but it was 
 ext4. Sorry for all the noise! However, I'm glad you have helped, and 
 that I have learned a little bit about Linux partitions as FreeeBSD 
 slices.

 It was empty, so I just reformatted it as ext2, and hey presto; all is 
 right with the world.

Good to know you have it working, but for future reference there is a
fuse implementation of an ext4 driver:

  sysutils/fusefs-ext4fuse  EXT4 implementation for FUSE
EXT4 implementation for FUSE.
WWW: https://github.com/gerard/ext4fuse/

I haven't tried it so I don't know how well it works.
-- 
Carl Johnsonca...@peak.org

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


Re: Mount Logical (ext2fs) Partitions?

2013-01-25 Thread Carl Johnson
Walter Hurry walterhu...@gmail.com writes:

 9.1 on x86_64.

 No doubt this question has been asked before, but how do I mount logical 
 partitions (e2fs) under FreeBSD? I have checked the handbook, and 
 DuckDuckGo'ed, but without finding anything useful.

 The third slice on my first disk is a physical one, and will mount 
 happily under FreeBSD.

From /etc/fstab:

 /dev/ada0s3 /Mail   ext2fs  rw00

 But I have a couple of logical partitions (also ext2fs) in the fourth 
 slice, which I have been trying, unsuccessfully, to mount.

 For information, here is the BSD view of the disk:

 $ sudo fdisk
 *** Working on device /dev/ada0 ***
 parameters extracted from in-core disklabel are:
 cylinders=310101 heads=16 sectors/track=63 (1008 blks/cyl)

 Figures below won't work with BIOS for partitions not in cyl 1
 parameters to be used for BIOS calculations are:
 cylinders=310101 heads=16 sectors/track=63 (1008 blks/cyl)

 Media sector size is 512
 Warning: BIOS sector numbering starts with sector 1
 Information from DOS bootblock is:
 The data for partition 1 is:
 sysid 131 (0x83),(Linux native)
 start 2048, size 24576000 (12000 Meg), flag 0
   beg: cyl 0/ head 32/ sector 33;
   end: cyl 1023/ head 254/ sector 63
 The data for partition 2 is:
 sysid 165 (0xa5),(FreeBSD/NetBSD/386BSD)
 start 24578064, size 44040150 (21503 Meg), flag 80 (active)
   beg: cyl 1023/ head 255/ sector 63;
   end: cyl 1023/ head 255/ sector 63
 The data for partition 3 is:
 sysid 131 (0x83),(Linux native)
 start 68618240, size 958464 (468 Meg), flag 0
   beg: cyl 1023/ head 254/ sector 63;
   end: cyl 1023/ head 254/ sector 63
 The data for partition 4 is:
 sysid 5 (0x05),(Extended DOS)
 start 69577576, size 243002520 (118653 Meg), flag 0
   beg: cyl 1023/ head 254/ sector 63;
   end: cyl 1023/ head 254/ sector 63
 $

 Now here's how Linux sees it:

 $ sudo fdisk -l /dev/sda

 Disk /dev/sda: 160.0 GB, 160041885696 bytes, 312581808 sectors
 Units = sectors of 1 * 512 = 512 bytes
 Sector size (logical/physical): 512 bytes / 512 bytes
 I/O size (minimum/optimal): 512 bytes / 512 bytes
 Disk identifier: 0x38d5b517

Device Boot  Start End  Blocks   Id  System
 /dev/sda120482457804712288000   83  Linux
 /dev/sda2   *245780646861821322020075   a5  FreeBSD
 /dev/sda36861824069576703  479232   83  Linux
 /dev/sda469577576   312580095   1215012605  Extended
 /dev/sda594158848   112590847 9216000   83  Linux
 /dev/sda6   112592896   118736895 3072000   82  Linux swap / 
 Solaris
 /dev/sda7   118738944   1596989432048   83  Linux
 /dev/sda8   159700992   2416209914096   83  Linux
 /dev/sda9   241623040   27029913514338048   83  Linux
 /dev/sda10  270301184   31258009521139456   83  Linux
 /dev/sda11   695808009415679912288000   83  Linux

There is a package called 'linuxfdisk' that is just a FreeBSD
implementation of the linux fdisk and will show you what the FreeBSD
partitions/slices are.  You can also use gpart in the base system to get
the same information.  The command 'gpart list ada0' will show the
primary partitions, and the command 'gpart list ada0s4' should show the
logical partitions inside of the extended partition.  You can also use
'file -s' and possibly do read-only mounts to see exactly what they
contain.  The names will probably map out like linux, but the 'sda*'
will be changed to 'ada0s*'.

-- 
Carl Johnsonca...@peak.org

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


Re: How to see all labels?

2013-01-24 Thread Carl Johnson
Carl Johnson ca...@peak.org writes:

 I recently installed 9.1 on a system and labels don't seem to work as
 I would expect.  I can get them to work in /etc/fstab, but only the
 ones referenced there show up in /dev/ufs and /dev/gpt.  I have seen
 this in previous versions, and in those cases they sometimes work.  In
 at least one previous case one ufs label (of several) would never work
 even in fstab.  The following shows my current configuration:

   $ uname -a
   FreeBSD bonsai.localnet 9.1-RELEASE FreeBSD 9.1-RELEASE #0 r243825:
   Tue Dec  4 09:23:10 UTC 2012
   r...@farrell.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  amd64  
   $ gpart backup ada0
   GPT 128
   1   freebsd-boot   64  128  
   2freebsd-ufs  192 35651584 Bonsai 
   3   freebsd-swap 35651776  4224671 BonsaiSwap 
   $ glabel status
 Name  Status  Components
   gptid/150b03ac-5767-11e2-a154-001485411fc8 N/A  ada0p1
   ufs/Bonsai N/A  ada0p2
   gpt/BonsaiSwap N/A  ada0p3
   $ ls -l /dev/ufs
   total 0
   crw-r-  1 root  operator0, 109 2013-01-08 09:42 Bonsai
   $ ls -l /dev/gpt
   total 0
   crw-r-  1 root  operator0, 112 2013-01-08 09:42 BonsaiSwap
   $ cat /etc/fstab
   # DeviceMountpoint  FStype  Options DumpPass#
   #/dev/ada0p2/   ufs rw  1   1
   #/dev/ada0p3noneswapsw  0   0
   /dev/ufs/Bonsai /   ufs rw  1   1
   /dev/gpt/BonsaiSwap noneswapsw  0   0

 In this case I have two GPT labels defined, but only the one used in
 fstab (BonsaiSwap) is shown in /dev/gpt and by glabel.  When I used
 the original fstab without labels, there were no /dev/gpt or /dev/ufs
 directories, and glabel didn't show any of them.

 Does anybody have any ideas about how to get the system to recognize
 all labels?  A command after boot would be acceptable since I could
 just put it in /etc/rc.local.

I just discoved the sysctl 'kern.geom.label.debug=2' and did some
further testing.  It appears that the system removes what it considers
redundant labels.  For the Bonsai label it has labels for ufs, ufsid,
gpt, and gptid;  so it removes the ufsid, gpt, and gptid labels after I
use the ufs label.  The swap partition has gpt and gptid labels, and it
removes the gptid label after I use the gpt label.  I don't really agree
with it, but I feel better about it now that I think I understand what
it is doing.

-- 
Carl Johnsonca...@peak.org

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


Re: ext3 file system

2013-01-20 Thread Carl Johnson
Ralf Mardorf ralf.mard...@rocketmail.com writes:

 Hi :)

 is it possible to mount Linux ext3 file systems with fstab by label?
 Before I run mount -a /mnt/dump had the same permissions, owner and
 group as /mnt/archlinux has got. Is it possible to keep this? Both are
 Linux  ext3 fs. Mounting without a label does work.

 root@freebsd:/usr/home/rocketmouse # cat /etc/fstab
 # Device  Mountpoint  FStype  Options Dump Pass
 /dev/ad4s1b   noneswapsw  0   0
 /dev/ad4s1a   /   ufs rw  1   1
 /dev/ad4s1e   /tmpufs rw  2   2
 /dev/ad4s1f   /usrufs rw  2   2
 /dev/ad4s1d   /varufs rw  2   2
 /dev/acd0 /cdrom  cd9660  ro,noauto   0   0
 #proc   /proc   procfs  rw  0   0
 /dev/ada0s8 /mnt/dump   ext2fs  rw  0   0
 #/dev/label/dump /mnt/dump   ext2fs  rw  0   0
 #/dev/label/archlinux/mnt/archlinux  ext2fs  rw  0   0

 root@freebsd:/usr/home/rocketmouse # ls -l /mnt
 total 6
 drwxr-xr-x  2 rocketmouse  wheel   512 Jan 20 20:51 archlinux
 drwxrwxrwx  2 root wheel  4096 Jan 20 20:09 dump
 root@freebsd:/usr/home/rocketmouse # ls -l / | grep mnt
 drwxr-xr-x4 root  wheel  512 Jan 20 20:51 mnt

 I still search the Internet, but had bad luck until now.

 If I run 'gpart show -l' I can't see what /dev archlinux is, it
 doesn't show Linux labels, so I need to restart and boot Linux to see
 at what  position it is, to figure out what /dev/ada*s* archlinux is.

You should be able to see any labels the kernel knows about with 'glabel 
status', but my experience is that not all labels show up.  You can
check ext2/3 labels with e2label from the e2fsprogs port/package.  My
experience is that labels in /etc/fstab work fine, but they may or may
not be visible in /dev or with glabel if they are not in fstab.

-- 
Carl Johnsonca...@peak.org

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


How to see all labels?

2013-01-10 Thread Carl Johnson
I recently installed 9.1 on a system and labels don't seem to work as
I would expect.  I can get them to work in /etc/fstab, but only the
ones referenced there show up in /dev/ufs and /dev/gpt.  I have seen
this in previous versions, and in those cases they sometimes work.  In
at least one previous case one ufs label (of several) would never work
even in fstab.  The following shows my current configuration:

  $ uname -a
  FreeBSD bonsai.localnet 9.1-RELEASE FreeBSD 9.1-RELEASE #0 r243825:
  Tue Dec  4 09:23:10 UTC 2012
  r...@farrell.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  amd64  
  $ gpart backup ada0
  GPT 128
  1   freebsd-boot   64  128  
  2freebsd-ufs  192 35651584 Bonsai 
  3   freebsd-swap 35651776  4224671 BonsaiSwap 
  $ glabel status
Name  Status  Components
  gptid/150b03ac-5767-11e2-a154-001485411fc8 N/A  ada0p1
  ufs/Bonsai N/A  ada0p2
  gpt/BonsaiSwap N/A  ada0p3
  $ ls -l /dev/ufs
  total 0
  crw-r-  1 root  operator0, 109 2013-01-08 09:42 Bonsai
  $ ls -l /dev/gpt
  total 0
  crw-r-  1 root  operator0, 112 2013-01-08 09:42 BonsaiSwap
  $ cat /etc/fstab
  # DeviceMountpoint  FStype  Options DumpPass#
  #/dev/ada0p2/   ufs rw  1   1
  #/dev/ada0p3noneswapsw  0   0
  /dev/ufs/Bonsai /   ufs rw  1   1
  /dev/gpt/BonsaiSwap noneswapsw  0   0

In this case I have two GPT labels defined, but only the one used in
fstab (BonsaiSwap) is shown in /dev/gpt and by glabel.  When I used
the original fstab without labels, there were no /dev/gpt or /dev/ufs
directories, and glabel didn't show any of them.

Does anybody have any ideas about how to get the system to recognize
all labels?  A command after boot would be acceptable since I could
just put it in /etc/rc.local.

-- 
Carl Johnsonca...@peak.org

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


Re: Reading the handbook from console

2013-01-10 Thread Carl Johnson
dte...@freebsd.org writes:

 -Original Message-
 From: Polytropon [mailto:free...@edvax.de]
 Sent: Thursday, January 10, 2013 3:41 PM
 To: dte...@freebsd.org
 Cc: 'Fbsd8'; scotteb...@gmail.com; questi...@freebsd.org
 Subject: Re: Reading the handbook from console
 
 On Thu, 10 Jan 2013 14:48:33 -0800, dte...@freebsd.org wrote:
 
 
   -Original Message-
   From: owner-freebsd-questi...@freebsd.org [mailto:owner-freebsd-
   questi...@freebsd.org] On Behalf Of Polytropon
   Sent: Thursday, January 10, 2013 2:33 PM
   To: Fbsd8
   Cc: scotteb...@gmail.com; questi...@freebsd.org
   Subject: Re: Reading the handbook from console
  
   On Thu, 10 Jan 2013 13:57:47 -0500, Fbsd8 wrote:
Scott Eberl wrote:
 I went ahead and installed the FreeBSD handbook onto my system and I
 was
 able to find it on disk per the motd notes but I'm wondering if there
 is a
 preferred method for reading these since they are in html format. I
 tried
 w3m and lynx and it looks like they are both not installed. Is there
 something i'm missing for reading these or do I just need to install 
 a
 cli
 browser?


Viewing html takes some form of browser.
  
   There is no text mode web browser in the base system.
   Installing one is easy: As the HTML files generated
   for the Handbook are good quality, they display nicely
   in lynx, links, and w3m (probably the most prominent
   three text mode web browsers).
  
  
 
  I must know...
 
  What is Polytropon's favorite of those listed? (and perhaps also elinks 
  ?)
 
 Hard to say, now that X is everywhere... :-)
 
 In the past, I've started using lynx because it was the
 default. Somehow I even tend to remember that it was part
 of the default installation in around FreeBSD 4 or so...
 but that could be wrong.
 
 Later on I tried w3m and also found it usable.
 
 Today I'd say I prefer links for interactive text mode
 browsing. Still lynx -dump is a welcome tool in some
 of my scripts, and never change a running system. :-)
 

 Ok, the reason I ask is actually because I have this insane (?) idea of 
 shoving
 one of the aforementioned solutions onto the installation media so that (gasp)
 we can have that functionality back like we had in the days of sysinstall.

 So naturally, my first question is which one?

 Thoughts?

I just looked at the DVD install disk and it has firefox, links1, links,
and w3m.  That should take care of most needs, but I don't know about
the CD disks.

-- 
Carl Johnsonca...@peak.org

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


Re: somewhat OT ... in parts

2013-01-05 Thread Carl Johnson
Polytropon free...@edvax.de writes:

 On Fri, 4 Jan 2013 13:59:45 -0800, Gary Kline wrote:
  maybe I should just find keith bostic's newvi; see if they have it 
  for linux; theyve got everything else... {grumble}

 I know there's nvi in ports.

 Maybe those will be helpful:

 http://garage.linux.student.kuleuven.be/~skimo//nvi/



 nvi download here:

 https://sites.google.com/a/bostic.com/keithbostic/files



 Project page and FAQ:

 https://sites.google.com/a/bostic.com/keithbostic/vi

The vi in FreeBSD is already nvi.  The name nvi is a link to vi in
/usr/bin and the source includes nvi at /usr/src/contrib/nvi/.

-- 
Carl Johnsonca...@peak.org

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


Re: Cannot boot - creating partition and installing FreeBSD is [solved]

2012-11-28 Thread Carl Johnson
Ralf Mardorf ralf.mard...@rocketmail.com writes:

 Installing PC-BSD 8.2 x64 did work without issues. I unchecked the
 bootloader install. Linux grub legacy until now is unable to boot BSD,
 because of Error17: Cannot mount selected partition

 spinymouse@q:~$ cat /boot/grub/menu.lst
 timeout   8
 default   0
 color light-blue/black light-cyan/blue

 title FreeBSD
 root   (hd0,a)
 kernel /boot/loader

 [snip]

 Linux only recognize the slice, but not what's inside it:
 spinymouse@q:~$ sudo fdisk -l

You might want to try a chainloader boot from grub.  The following is a
chainloader rule that I have used, as well as a normal loader boot.  I
use the loader boot, but I also tested the chainloader boot.  You will
need a ufs2_stage1_5 file in your grub directory for a loader boot, and
linux grub might not have it available.

title   FreeBSD, sda3 (oak) chainloader
root(hd1,2)
chainloader +1
boot

title   FreeBSD, sda3 (oak) /boot/loader
root(hd1,2,a)
kernel  /boot/loader
boot

-- 
Carl Johnsonca...@peak.org

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


Re: ata controller problem

2012-10-27 Thread Carl Johnson
Gerhard Schmidt schm...@ze.tum.de writes:

 Labels are good for naming Drives but how does it help me if the root
 filesystem changing device ids. I don't think the boot loader is able to
 use the label for the root Filesystem.

From my fstab:
/dev/ufs/Oak /  ufs rw,noatime 1 1
/dev/label/OakSwap   none   swapsw 0 0

I think any of the other label schemes will also work.  If you don't
remember which label is which device id, then 'glabel status' will show
that, but you shouldn't need to.

-- 
Carl Johnsonca...@peak.org

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


Re: help about free bsp version netcat to work it on ubuntu

2012-07-24 Thread Carl Johnson
lei yang yanglei.f...@gmail.com writes:

 On Tue, Jul 24, 2012 at 12:03 AM, Carl Johnson ca...@peak.org wrote:
 lei yang yanglei.f...@gmail.com writes:

 On Mon, Jul 23, 2012 at 12:25 AM, Polytropon free...@edvax.de wrote:
 On Sun, 22 Jul 2012 22:41:57 +0800, lei yang wrote:
 Hi,

 I want to build a netcat on my local pc (ubuntu) with gcc, is it
 possible? I'm new to free bsd



 it has no -U flag, can you point me where I get this version

 Have you checked the other version of netcat already available?  A quick
 check shows these four versions for Ubuntu:

 netcat: TCP/IP swiss army knife -- transitional package
 netcat-openbsd: TCP/IP swiss army knife
 netcat-traditional: TCP/IP swiss army knife
 netcat6: TCP/IP swiss army knife with IPv6 support


 how did you get the list?

I used the surfraw package which is available on freebsd, debian, and
ubuntu.  In this case I just used 'debpackages -u netcat' to do access
the ubuntu packages search page.  There is also 'freebsd -psearch' to
search freebsd ports, and debpackages without -u shows debian packages.

 To be clear, haha, I just want to know how to build a fress bsd netcat
 on a no-fressbsd platform

Others have probably already mentioned this, but you are probably better
off trying ports source instead.  Most of those are written to be
portable and are easily configured for other OSs.  Freebsd port search
shows the following for netcat:

net/cryptcat  Standard netcat enhanced with twofish encryption
net/gnetcat   GPL'ed re-write of the well known networking tool 
netcat
net/nc6   Netcat clone with IPv6 support
net/netcatSimple utility which reads and writes data across 
network connections
net/sbd   A netcat clone with more features and crypto
net/scnc  SSL Capable Netcat
security/sst  A simple SSL tunneling tool (uses netcat)

-- 
Carl Johnsonca...@peak.org

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


Re: help about free bsp version netcat to work it on ubuntu

2012-07-23 Thread Carl Johnson
lei yang yanglei.f...@gmail.com writes:

 On Mon, Jul 23, 2012 at 12:25 AM, Polytropon free...@edvax.de wrote:
 On Sun, 22 Jul 2012 22:41:57 +0800, lei yang wrote:
 Hi,

 I want to build a netcat on my local pc (ubuntu) with gcc, is it
 possible? I'm new to free bsd



 it has no -U flag, can you point me where I get this version

Have you checked the other version of netcat already available?  A quick
check shows these four versions for Ubuntu:

netcat: TCP/IP swiss army knife -- transitional package
netcat-openbsd: TCP/IP swiss army knife
netcat-traditional: TCP/IP swiss army knife
netcat6: TCP/IP swiss army knife with IPv6 support

-- 
Carl Johnsonca...@peak.org

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


Re: find date of last boot

2012-06-07 Thread Carl Johnson
Fbsd8 fb...@a1poweruser.com writes:

 dmesg command does not show date of last boot.

 Are there some other commands to find date of last boot?

In addition to the other responses:

sysctl kern.boottime

-- 
Carl Johnsonca...@peak.org

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


Re: libc regex word-boundary support fallen-off?

2012-03-08 Thread Carl Johnson
RW rwmailli...@googlemail.com writes:

 I've noticed for some time that claws-mail and less (which I think use
 libc's regex(3)) don't support word boundaries in searches. I might be
 delusional, but I think I've used \b in the past in both of those
 applications in FreeBSD.  

 According to regex(3) it's an implementation POSIX.2, so the feature
 needn't be supported, but at the bottom of the page it says
 word-boundary matching is a bit of a kludge, so presumably it has
 been.

 Does anyone know what's going on?


 I switched from i386 to amd64 last year so it might be something to do
 with that. I'm currently using 8.2p6.

The only way I have found to do it is [[::]] and [[::]].  That is very
awkward, so I't love to hear of a shorter way.  I found them in the
re_format(7) manpage.
-- 
Carl Johnsonca...@peak.org

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


Re: VBox network boot

2012-02-29 Thread Carl Johnson
Warren Block wbl...@wonkity.com writes:

 On Tue, 28 Feb 2012, Carl Johnson wrote:

 Warren Block wbl...@wonkity.com writes:

 On Tue, 28 Feb 2012, Da Rock wrote:

 I'm starting to believe this dog won't hunt (in fact is dead,
 bloated, and full of worms...); but has anyone got a solution for
 network booting in VBox on FBSD host?

 To PXE-boot a VM guest, set networking to to Bridged and use the
 PCnet-PCI II (Am79C970A) adapter type.  If the host is FreeBSD, the
 vboxnet kernel module has to be loaded.

 Please emphasize that the PCnet-PCI II card emulation is necessary.

 Updated in the PXE article, thanks.

Thank you, that makes it perfectly clear.  I had initially ignored that
suggestion, thinking that it wasn't important!
-- 
Carl Johnsonca...@peak.org

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


Re: VBox network boot

2012-02-28 Thread Carl Johnson
Warren Block wbl...@wonkity.com writes:

 On Tue, 28 Feb 2012, Da Rock wrote:

 I'm starting to believe this dog won't hunt (in fact is dead,
 bloated, and full of worms...); but has anyone got a solution for
 network booting in VBox on FBSD host?

 To PXE-boot a VM guest, set networking to to Bridged and use the
 PCnet-PCI II (Am79C970A) adapter type.  If the host is FreeBSD, the
 vboxnet kernel module has to be loaded.

Please emphasize that the PCnet-PCI II card emulation is necessary.  I
was trying the Intel emulation and making no progress.  I then noticed
your page and tried the PCnet-PCI II card and it started working.  I
would guess that means their Intel card emulation is incomplete.
-- 
Carl Johnsonca...@peak.org

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


Re: One or Four?

2012-02-18 Thread Carl Johnson
Erich Dollansky er...@alogreentechnologies.com writes:

 Hi,

 On Sunday 19 February 2012 04:34:17 Jerry McAllister wrote:
 On Sat, Feb 18, 2012 at 12:07:30PM +0100, Damien Fleuriot wrote:
 
  
 
 So, Polytropon's three choice pattern is good.   Or, I could even
 suggest just two choices.  
 
 yes, three options is ok.

  [ ] all in one + swap
Create one partition containing all subtrees
plus one swap partition.

  [ ] user-defined
Make your own partitioning selection manually.
(Both number and size of partitions)
with a reasonable way to specify partitions and sizes.
The old Sysinstall way is not bad, but if it obsolete, 
then something as easy that fits the new GPT based system.
 
 A normal user will use the first option here and get screwed when the
 file system got affected by a power failure. The second option is not
 an option for a general user. 

What will happen in the case of a power failure?  I just see an fsck
when that happens, and I have been running unix and linux for about 20
years.  I have always had multiple partitions in the past, but for 9.0 I
went with the single partition.

-- 
Carl Johnsonca...@peak.org

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


Re: FreeBSD 9 and 3G Modems

2012-01-26 Thread Carl Johnson
Odhiambo Washington odhia...@gmail.com writes:

 On Wed, Jan 25, 2012 at 18:54, Mike Tancsa m...@sentex.net wrote:

 On 1/25/2012 5:43 AM, Odhiambo Washington wrote:
 
  I have a Huawei E1820
 
  I will also try RTFM.

 Hi,
kldload u3g
kldload umodem


 Done, although kldload u3g tells me that file already exists! Perhaps
 because I booted up with my Huawei dongle plugged in.
 kldstat | grep u3g shows me nothing though.

The command 'kldstat -v' shows that u3g is already compiled in for the
9.0-RELEASE kernel.

-- 
Carl Johnsonca...@peak.org

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


Re: kgzip(8) regression in RELENG_9 GENERIC

2012-01-23 Thread Carl Johnson
Devin Teske devin.te...@fisglobal.com writes:

 On Jan 23, 2012, at 12:56 AM, CyberLeo Kitsana wrote:

 On 01/23/2012 12:30 AM, Devin Teske wrote:
 
 On Jan 21, 2012, at 1:41 AM, CyberLeo Kitsana wrote:
 
 On 01/20/2012 09:02 PM, Devin Teske wrote:
 Taking a GENERIC 9.0-RELEASE kernel and running kgzip(8) on it produces an
 unusable kernel which causes immediate BTX halt in loader(8).
 
 ...
 
 4. Say: kgzip kernel
 
 Curious, it doesn't even look like that binary is hooked into the build
 process at all on 9.0-RELEASE.
 
 
 Can you clarify what you mean by the above?
 
 On a brand new GENERIC box running 9.0-RELEASE with no special knobs:
 
 8
 (4b18d544)[cyberleo@jenga ~]$ which kgzip

 On my box:

 push900# uname -a
 FreeBSD push900.vicor.com 9.0-RELEASE FreeBSD 9.0-RELEASE #0: Tue Jan  3 
 07:15:25 UTC 2012 
 r...@obrian.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  i386

 push900# which kgzip
 /usr/sbin/kgzip

On my system:

$ uname -a
FreeBSD birch.localnet 9.0-RELEASE FreeBSD 9.0-RELEASE #0: Tue Jan  3 07:46:30 
UTC 2012 r...@farrell.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  amd64
$ whereis kgzip
kgzip: /usr/src/usr.sbin/kgzip
$ grep kgzip /usr/src/usr.sbin/Makefile*
Makefile.amd64:# kgzip: builds, but missing support files
Makefile.i386:SUBDIR+=  kgzip

So it appears to be i386 only.

-- 
Carl Johnsonca...@peak.org

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


Re: Installing FreeBSD ver. 8.2

2012-01-07 Thread Carl Johnson
Polytropon free...@edvax.de writes:

 On Sat,  7 Jan 2012 15:05:55 -0800 (PST), leeoliveshackelf...@surewest.net 
 wrote:
 (1)  Does anyone know how to get FreeBSD to read the
 motherboard name?  This name, on an xw4400, starts with
 HP followed by a eleven digits, and is given in Windows
 XP as Full Computer Name on the Computer Name tab
 of the System Properties window.  Among other purposes,
 this name is used by Novell network operating system to
 distinguish hosts on a subnet.

 The OS provides the output of dmesg and maybe the
 output of pciconf -lv, as well as the sysctl value
 dev.acpi.0.%desc which may contain the required
 information. However, I'm sure there is a program
 in the ports collection that can be used to obtain
 that kind of information.

 Try:

   dmesg | grep HP
   sysctl -a | grep HP
   pciconf -lv | less

 and see if there's such a number mentioned. Maybe
 you can also use acpidump to retrieve that information
 from the ACPI datasets.

The 'kenv' command seems to have the board name available as
'smbios.system.product'.  The 'kenv' command without arguments will show
all values, so you can make sure that is the proper variable.

-- 
Carl Johnsonca...@peak.org

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


Re: OT: Root access policy

2011-12-29 Thread Carl Johnson
Damien Fleuriot m...@my.gd writes:

 On 12/29/11 10:58 AM, Polytropon wrote:
 On Thu, 29 Dec 2011 04:01:42 -0500, Irk Ed wrote:
 For the first time, a customer is asking me for root access to said
 customer's servers.
 
  snip
 Assuming that I'll be asked to continue administering said servers, I guess
 I should at least enable accounting...
 
 You could have better success using sudo. Make sure
 the customer is allowed to sudo command. The
 sudo program will log _all_ things the customer
 does, so you can be sure you can review actions.
 Furthermore you don't need to give him the _real_
 root password. He won't be able to su root or
 to login as root, _real_ root. But he can use
 the sudo prefix to issue commands with root
 privileges.
 

 sudo su - or sudo sh and the customer gets a native root shell which
 does *not* log commands !

The sudoers manpage mention the noexec option which is designed to help
with the first problem.  They also show an example using !SHELLS which
can help with the second.

-- 
Carl Johnsonca...@peak.org

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


Re: Problems with pkg_upgrade

2011-12-25 Thread Carl Johnson
David Jackson djackson...@gmail.com writes:

 Since I wish to use packages instead of ports to update my system, someone
 recommended I use pkg_upgrade. However, basically, it does not work. It
 gets to downloaded packages. But, after 10 packages, it prints a message
 Protocol error and then Package x cannot be fetched, where x is the
 name of the pavkage it stops at. I can restart pkg_upgrade, it downloads 10
 more packages where it stopped previously, but then gives this same message
 again. Maybe the connection to the FTP server os being lost and code needs
 to be added to automatically restart the FTP connection without the whole
 thing crashing?

 I do think packages need to be better supported on FreeBSD, many users do
 prefer to use packages due to speed and convenience and do not prefer to
 build it all. it shouldnt be such a hassle

I can't help directly with your problem, but both portupgrade and
portmaster support packages.  In both cases you can just supply the -P
or -PP options to specify how to handle packages.  I think they both
require that the ports tree be present for the /usr/ports/INDEX file,
but otherwise they can use just packages.
-- 
Carl Johnsonca...@peak.org

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


Re: sudo log messages

2011-12-04 Thread Carl Johnson
Коньков Евгений kes-...@yandex.ru writes:

 Здравствуйте, Polytropon.

 Вы писали 4 декабря 2011 г., 15:41:45:

 P On Sun, 4 Dec 2011 05:34:19 +0200, Коньков Евгений wrote:
 Tell me please how to stop sudo to food /var/log/messages?

 P ADDITION: Of course I meant /usr/local/etc/sutoers,
 P NOT sudo.conf.

 P Instead of logging via syslog (to /var/log/messages),
 P why not use a specific log file for sudo? Add those
 P lines to the sudoers file:

 P Defaults logfile=/var/log/sudo.log
 P Defaults !syslog

 P Make sure /var/log/sudo.log exists, and maybe use
 P newsyslog.conf to deal with log rotation and archiving.
 P However, you can easily purge sudo log information
 P this way, if required.

 P The file /usr/local/share/doc/sudo/sample.sudoers
 P contains an example.

 yes, that is not problem, but I want to control logging in one place
 not in each config file of service I have ran on machine.

 I have thought that this
 !sudo
 *.* /var/log/sudo.log
 will take off logging in /var/log/messages but this work as
 log to /var/log/messages and to /var/log/sudo.log =((

You are not clear about what you really want.  If you want it to log to
auth.log instead of messages, then you can use the following in your
sudoers file:

   Defaults syslog=authpriv

The sample file that was mentioned earlier is one source for
information, but the best source is the sudoers(5) man page.  Just
search it for syslog and you will find several settings.

-- 
Carl Johnsonca...@peak.org

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


Re: Invalid fdisk partition table found

2011-11-23 Thread Carl Johnson
Julian H. Stacey j...@berklix.com writes:


 @ suggestions:
 1 Try
   bsdlabel -B -w -r /dev/da1
   echo unplug, reinsert
   newfs /dev/da1a

 2 Base of _my_ man fdisk
  When running multi user, you cannot write unless you first run this:
  sysctl kern.geom.debugflags=16
 

 It looks like I never got round to sending in a send-pr for that, so feel free
 looks like its been that way at least since 7.1.see
 http://berklix.com/~jhs/src/bsd/fixes/FreeBSD/src/gen/sbin/fdisk/

I thought I had seen a mention of that somewhere, so I grep'ed the man
pages.  I found hints on geom(4) and boot0cfg(8), but they certainly
aren't obvious.

-- 
Carl Johnsonca...@peak.org

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


Re: ntpdate on boot problem

2011-11-05 Thread Carl Johnson
Matthew Seaman m.sea...@infracaninophile.co.uk writes:

 On 05/11/2011 22:19, Robert Simmons wrote:
 On Sat, Nov 5, 2011 at 6:03 PM, Alexander Best arun...@freebsd.org wrote:
 same here. simply add something like the following to your crontab:

 0   10  *   *   */2 /etc/rc.d/ntpdate onestart
 
 I have something similar in my crontab which is not exactly what I
 need.  I want to make sure that the clock is set at every boot because
 I'm using this as a kerberos server.  If the clock is not set properly
 at boot, kerberos will not work properly until the nightly cron jobs
 are run and the clock is set then.  I need everything working at boot.
  I can't have a window of problems between boot and midnight or
 whenever cron runs ntpdate.

 crontabs have this handy '@reboot' syntax...  It's all explained in
 crontab(5).

Just be aware that 'Run once, at startup', means when 'cron' starts, not
just when the system boots, unless they have changed it recently.

-- 
Carl Johnsonca...@peak.org

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


Re: How to get /dev/smb* ?

2011-11-02 Thread Carl Johnson
Антон Клесс rc5h...@yandex.ru writes:


 mbmon is very old.  I've never gotten it to work on any machine I've
 every tried it on.

 Does your boot time output show anything smb-related at all, such as
 maybe smbios0: System Management BIOS at ...?  It's possible that
 your machine simply has no support for this.


 # dmesg -a |grep smb

 - returns nothing.

 Does it means that it is no way to read temperature sensors on motherboard?

Have you tried:

  $ sysctl -a | grep temperature
  dev.cpu.0.temperature: 29.2C
  dev.cpu.1.temperature: 29.2C

for your system?
I have an AMD cpu and the amdtemp kernel module provides that
information.  I am not familiar with the Intel cpus, but the coretemp
module is supposed to provide the same information for them.  I use
gkrellm for various thing, and it will display that information
directly.

-- 
Carl Johnsonca...@peak.org

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


Re: How to dual-boot FreeBSD 9 with Linux?

2011-10-28 Thread Carl Johnson
Unga unga...@yahoo.com writes:

 Hi all

 Is any one by now successfully dual-booting FreeBSD 9 with Linux?

 I have tried with OpenSuse 11.4 with FreeBSD 9. OpenSuse installs
 Grub1 to mbr. Grub1 doesn't seem to support FreeBSD 9. It cannot
 recognise the file system type.

 Any help in this regard is very much appreciated.

It isn't very difficult and there are at least two ways to do it.
Grub1 actually does support ffs and ufs2 file systems, but the linux
distributions don't seem to include the drivers.  If you can get the
source, that should have all of them.  I think that I just got the grub
package from the FreeBSD file system and copied the additional drivers
directly into my linux grub directory, but I am not sure now.

The other way is to use the 'chainloader' command.  You just specify the
disk and partition (slice) with the root command, and then add the
commands 'chainloader +1' and 'boot'.  The chainloader command just
means to boot whatever is at the first sector of the previously
specified disk and slice.  I think the first sector of a ufs2 file
system just jumps to the loader.

The menu items from mine are just:

title   FreeBSD /boot/loader
root(hd1,2,a)
kernel  /boot/loader
boot

title   FreeBSD chainloader
root(hd1,2)
chainloader +1
boot

In my case, those specifies that they use the third slice on the second
disk.  The first menu item requires that you already have the
'ufs2_stage1_5' file in your grub directory.

-- 
Carl Johnsonca...@peak.org

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


Re: nice man pages?

2011-10-26 Thread Carl Johnson
Thomas Dickey dic...@radix.net writes:

 fwiw, without also setting the NC capability (something like NC#35),
 it'll confuse curses/ncurses since that conflicts with the normal
 color controls.

Thanks, I had missed that description in the terminfo(5) manpage.  It
worked fine without it, but that might have been just because I hadn't
been using enough colors.  I put it in but there is no change for my
applications.

-- 
Carl Johnsonca...@peak.org

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


Re: nice man pages?

2011-10-26 Thread Carl Johnson
Carl Johnson ca...@peak.org writes:

 Patrick Lamaiziere patf...@davenulle.org writes:

 Hello,

 I use sysutils/most to have nice manual pages in color, that's cool but
 is there a way to do this with the base system (ie without adding port)?

 I use a colorized termcap with less, but it also works with
 /usr/bin/more.  It depends on what type of terminal you are using it
 on.  I have it for xterm and rxvt (which is what I use).  This works for
 manpages, but you can also colorize your prompt.

Obviously I hadn't thought that through since there is no xterm in the
base system, but both the xterm and rxvt termcap entries seem to work on
the console.  Just to be sure I made up a colorized cons25 entry.  I
left in the underline attribute, even though the console doesn't seem to
support underline.  I also added the nc capability that Thomas Dickey
suggested should be used.  The revised version of my ~/.termcap is below
if anybody is interested:

 start ~/.termcap -
# these are just changes to the standard FreeBSD termcap - 2010-12-13 cdj
# added cons25 and nc capability - 2011-10-26 cdj

xterm|xterm-color|X11 terminal emulator:\
:md=\E[33;1m:so=\E[36;1m:se=\E[0m:us=\E[32;4m:ue=\E[0;24m:nc#35:\
:ti@:te@:tc=xterm-xfree86:

rxvt|rxvt terminal emulator (X Window System):\
:md=\E[33;1m:so=\E[36;1m:se=\E[0m:us=\E[32;4m:ue=\E[0;24m:nc#35:\
:pa#64:Co#8:AF=\E[3%dm:AB=\E[4%dm:op=\E[39;49m:\
:tc=rxvt-mono:

cons25|colorized version of cons25|:\
:md=\E[33;1m:so=\E[36;1m:se=\E[0m:us=\E[32;4m:ue=\E[0;24m:nc#35:\

:ac=l\332m\300k\277j\331u\264t\303v\301w\302q\304x\263n\305`^Da\260f\370g\361~\371.^Y-^Xh\261i^U0\333y\363z\362:\
:tc=cons25w:
 end ~/.termcap -

Note that the ac capability in cons25 should be a single (long) line.

-- 
Carl Johnsonca...@peak.org

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


Re: nice man pages?

2011-10-25 Thread Carl Johnson
Patrick Lamaiziere patf...@davenulle.org writes:

 Hello,

 I use sysutils/most to have nice manual pages in color, that's cool but
 is there a way to do this with the base system (ie without adding port)?

I use a colorized termcap with less, but it also works with
/usr/bin/more.  It depends on what type of terminal you are using it
on.  I have it for xterm and rxvt (which is what I use).  This works for
manpages, but you can also colorize your prompt.

It is short, so my ~/.termcap is below:

-- snip ---
# this is just changes to the standard FreeBSD termcaps - 2010-12-13 cdj

xterm|xterm-color|X11 terminal emulator:\
:md=\E[33;1m:so=\E[36;1m:se=\E[0m:us=\E[32;4m:ue=\E[0;24m:\
:ti@:te@:tc=xterm-xfree86:

rxvt|rxvt terminal emulator (X Window System):\
:md=\E[33;1m:so=\E[36;1m:se=\E[0m:us=\E[32;4m:ue=\E[0;24m:\
:pa#64:Co#8:AF=\E[3%dm:AB=\E[4%dm:op=\E[39;49m:\
:tc=rxvt-mono:
-- snip ---

All that does is set bold to yellow, standout to cyan, and underline to
green.  I use white on black, so if you use something else you will
probably have to adjust the colors.  I haven't tried 9.0, but this works
on 8.1-RELEASE and 8.2-RELEASE.  You can decide for yourself if that
does what you want.

-- 
Carl Johnsonca...@peak.org

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


Re: Help needed: sound/audio only semi-working

2011-10-23 Thread Carl Johnson
Carl Johnson ca...@peak.org writes:

 Ronald F. Guilmette r...@tristatelogic.com writes:

 I've been bringing up a new amd64 box with 8.2-RELEASE.  So far I've managed
 to get everything installed OK, including a boatload of freshly-built ports.
 I've even gotten flash10 working with firefox... well...

 Unfortunately, this is only MOSTLY working.  The video works great, but for
 audio all I get is absolute silence.

__snip__

 I also have a Gigabyte board with HDA audio, and it won't directly play
 CD sound either.  I had already ripped all of my CDs to .ogg files, so I
 hadn't needed to play the CDs directly.  I just tested ripping a small
 section of a CD using cdparanoia and it does produce a .wav audio file
 that can be played using sox.  I also notice on my computer that mixer
 doesn't show any controls for CD audio.  Unfortunately, I don't remember
 if CDs worked properly on this computer when I had Linux installed, so I
 don't know if the problem is FreeBSD or the motherboard.  I did find
 that I have a program called kscd (for KDE) that will play, but I
 suspect that it uses digital extraction instead of playing from audio.

 My system uses a Gigabyte GA-MA785GPM-US2H, and the sndstat output is:
 FreeBSD Audio Driver (newpcm: 64bit 2009061500/amd64)
 Installed devices:
 pcm0: HDA ATI RS690/780 HDMI PCM #0 HDMI (play)
 pcm1: HDA Realtek ALC885 PCM #0 Analog (play/rec) default
 pcm2: HDA Realtek ALC885 PCM #1 Analog (play/rec)
 pcm3: HDA Realtek ALC885 PCM #2 Digital (play/rec)

Just to follow up, I just rebooted into Linux and the CD audio appears
to work properly on it and the CD mixer control seems to work
properly.  I have FreeBSD 8.1-RELEASE, so it may have changed since
then.

-- 
Carl Johnsonca...@peak.org

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


Re: Help needed: sound/audio only semi-working

2011-10-21 Thread Carl Johnson
Ronald F. Guilmette r...@tristatelogic.com writes:

 I've been bringing up a new amd64 box with 8.2-RELEASE.  So far I've managed
 to get everything installed OK, including a boatload of freshly-built ports.
 I've even gotten flash10 working with firefox... well...

 Unfortunately, this is only MOSTLY working.  The video works great, but for
 audio all I get is absolute silence.

 The really strange thing is that after I followed all the directions here:

http://www.freebsd.org/doc/en/books/handbook/sound-setup.html

 This command:

 cat /dev/random  /dev/dsp

 *does* produce quite a bit of white noise sound.  However when I perform
 the other officially recommended basic audio functionality test:

 cdcontrol -f /dev/acd0 play 1

 with one of my favorite old audo CDs in the drive (AND with that special
 little wire running from the back of the drive to my motherboard) all that
 happens is that the CD/DVD drive apparently _does_ start to read some stuff...
 as evidenced by the blinking access light in the front of the drive... but I
 still get no sound out, and YouTube videos still aren't giving me any audio
 even though the video seems to be playing perfectly.

 So, um, I am grasping for ideas here on how I can debug this problem furher.
 I really have no idea what to do next to get this debugged.  I supposed that
 if nobody gives me a good suggestion, I'm gonna try swapping out that special
 little wire for another one and then try swapping the CD/DVD drive for another
 one if that still doesn't solve it.

 Sigh.  :-(  I just checked and yes, the CD/DVD drive _can_ mount a data CD
 alright.  No problems doing that.

 So how can it be that this works just fine:

cat /dev/random  /dev/dsp

 even while this:

   cdcontrol -f /dev/acd0 play 1

 causes the disk to spin up and read, but otherwise produces utter silence?

 I'm flummoxed.

 Any help would be appreciated.


 Regards,
 rfg



 P.S.  My motherboard (w/ onboard audio) is a Gigabyte GA-M55Plus-S3G.  Here
 is what a get when I cat /dev/sndstat:

 FreeBSD Audio Driver (newpcm: 64bit 2009061500/amd64)
 Installed devices:
 pcm0: HDA Realtek ALC883 PCM #0 Analog (play/rec) default
 pcm1: HDA Realtek ALC883 PCM #1 Analog (play/rec)
 pcm2: HDA Realtek ALC883 PCM #2 Digital (play/rec)

 Additional info:

 % sysctl hw.snd.default_unit
 hw.snd.default_unit: 0

I also have a Gigabyte board with HDA audio, and it won't directly play
CD sound either.  I had already ripped all of my CDs to .ogg files, so I
hadn't needed to play the CDs directly.  I just tested ripping a small
section of a CD using cdparanoia and it does produce a .wav audio file
that can be played using sox.  I also notice on my computer that mixer
doesn't show any controls for CD audio.  Unfortunately, I don't remember
if CDs worked properly on this computer when I had Linux installed, so I
don't know if the problem is FreeBSD or the motherboard.  I did find
that I have a program called kscd (for KDE) that will play, but I
suspect that it uses digital extraction instead of playing from audio.

My system uses a Gigabyte GA-MA785GPM-US2H, and the sndstat output is:
FreeBSD Audio Driver (newpcm: 64bit 2009061500/amd64)
Installed devices:
pcm0: HDA ATI RS690/780 HDMI PCM #0 HDMI (play)
pcm1: HDA Realtek ALC885 PCM #0 Analog (play/rec) default
pcm2: HDA Realtek ALC885 PCM #1 Analog (play/rec)
pcm3: HDA Realtek ALC885 PCM #2 Digital (play/rec)

Let me know if you want further information.
-- 
Carl Johnsonca...@peak.org

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


Re: Freebsd, Virtual OSs and GUI

2011-10-12 Thread Carl Johnson
Adam Vande More amvandem...@gmail.com writes:

 On Wed, Oct 12, 2011 at 5:38 PM, Jorge Biquez jbiq...@intranet.com.mxwrote:

 It is better to install KDE or GNOME as the base GUI or it is better to have
 any other ? (I do not know what could be).


 This is one of those ask a hundred different people get 100 different
 answers.  I prefer KDE which would work well for you because both KDE and
 VirtualBox are built on QT4, a rather large system.  KDE isn't really that
 heavy though relatively speaking.  VirtualBox runs great for me and does all
 you indicated.



 What do you think is the best option to save hardware resources and
 accomplish this task ? Something important is that this lab machine will be
 connected directly with the ISP (public IP's)  and I will need to connect
 remotely to control the server and the other OS's.


 You will probably want a CPU and chipset that has hardware assist for
 virtualization, and plenty of RAM for both host and guests.  Disk choice
 should reflect your data capacity, redundancy, and speed needs.  A good
 quality Intel NIC is always nice.

If the OP is going to run a 64-bit OS, then hardware vitualization
assist is *required* for VirtualBox to handle it.  It is not required
when VirtualBox is running a 32-bit OS.  Just another minor detail to
consider.

-- 
Carl Johnsonca...@peak.org

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


Re: snd_hda: how to configure line-in passthrough to line-out?

2011-10-05 Thread Carl Johnson
Brandon Kuczenski bran...@301south.net writes:

 I'm working on the sound on my system running 8.2-RELEASE.  Currently
 I have sound input and output working using snd_hda (i.e. I can record
 on line in, and play it back on line out).

 What I would like to do is take the audio coming in on line-in and
 send it back out the line-out live without recording it.

 Is this easy to do?  I'd appreciate any hints.

I do that all the time, so it definitely is not a problem.  I find on my
card that the output volume is controlled by a combination of 'volume'
and 'mix' settings in mixer(8).  I also must have the 'igain' set to
something above 0, but the volume isn't directly controlled by it.
-- 
Carl Johnsonca...@peak.org

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


Re: Timeline for 9.0-RELEASE?

2011-10-05 Thread Carl Johnson
Brett Glass br...@lariat.net writes:

 Just looked at the project Web site, and the timeline for 9.0-RELEASE
 is way, way out of date. If all goes well, when is 9.0 expected to be
 released? What remains to be done?

There is another web page at http://wiki.freebsd.org/Releng/9.0TODO that
has been partially updated.  That will at least give you some idea about
the schedule.

-- 
Carl Johnsonca...@peak.org

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


Re: Help Finding ZFS snapshots

2011-09-05 Thread Carl Johnson
Gene f...@brightstar.bomgardner.net writes:

 On Mon, 05 Sep 2011 10:48:22 -0400, Daniel Staal wrote
 --As of September 5, 2011 8:13:52 AM -0500, Gene is alleged to have said:
 
  Using FreeBSD 8.1, amd64 - I wanted to recover files from a snapshot of
  usr/home. Everything I've found via googling refers to a link such as
  path/zfs/.snapshot
 
 --As for the rest, it is mine.
 
 Try path/.zfs.  ;)
 
 (Which, on my system, then has a 'snapshot' directory, which holds 
 all the snapshots.)
 
 Daniel T. Staal


 No such luck. The following:

 cd /
 ls -R | grep -i zfs

 finds only 'zfs' directories in the source tree and ports.

 Other ideas? I know the snapshots exist, I can see 'em with 
 zfs list -t snapshot.

The .zfs directory is hidden by default so you have to specifically ls
or go into them.  Do a 'ls' on the base directory of any zfs file
system, and then add .zfs to the end and you should see the .snapshots
directory.
-- 
Carl Johnsonca...@peak.org

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


Re: cpio command and schg flags

2011-09-05 Thread Carl Johnson
Polytropon free...@edvax.de writes:

 On Mon, 5 Sep 2011 11:32:05 -0400, joeb1 wrote:
 I am trying to use this code sequence to clone a directory tree.
 mkdir /usr/test1
 cd /var
 find . | cpio -dmp  /usr/test1
 
 The result is  /usr/test1 gets populated with the directory tree but
 all the schg flags get stripped off. 
 
 How can I keep the schg flags in the cloned directory?

 As far as I remember, cpio doesn't copy flags. But you
 can use either dump + restore, or dpdup (from ports).

From man cpdup:

   The cpdup utility makes an exact mirror copy of
   the source in the destination, creating and
   deleting files and directories as necessary.
   UTimes, hardlinks, softlinks, devices, permissions,
   and flags are mirrored.

 Flags are explicitely mentioned here. Maybe you can give
 this program a try?

I think that tar will also work (but not gnu tar), and it is part of the
base system.  The manpage does show an example of how to do this, but
calls it moving the file heirarchy.

-- 
Carl Johnsonca...@peak.org

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


Re: Is there way to get filename for specific LBA?

2011-08-31 Thread Carl Johnson
per...@pluto.rain.com writes:

 Robert Bonomi bon...@mail.r-bonomi.com wrote:

  Aug 31 05:13:24 da kernel: ad6: WARNING - READ_DMA UDMA ICRC
  error (retrying request) LBA=107491647
  ... I looked at bsdlabel a   it's partition f, /home. But what
  is the file name?

 There's *no* easy way to find out.  You'll have to grovel through
 all the filesystem metadata, and the layers of index blocks for
 every file until you find the 'rgiht' one.

 This is what icheck -B was for, but icheck(8) no longer exists and
 that particular bit of functionality does not seem to be provided in
 fsck(8).

 One current userland utility (other than fsck) which does know
 how to grovel through the metadata and index blocks is dump(8),
 but you'd have to hack on it to report which inode was using a
 particular block.

It looks like the best bet would be fsdb, assuming that it is a UFS
file system.  That does have a 'findblk' command to find a file
containing a block, but you would need to calculate the block offset in
the filesystem first.  It doesn't look like it would be easy, as was
said earlier.

-- 
Carl Johnsonca...@peak.org

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


Re: new to os

2011-08-19 Thread Carl Johnson
Lars Eighner luvbeas...@larseighner.com writes:

 On Fri, 19 Aug 2011, Julian H. Stacey wrote:

 Aloha Lars,

 You mentioned WP5 in this thread. I have some docs on disks that were
 created in WP5. You know any FreeBSD based app like abiword that can
 read them for transfer to a contemporary program?

 Do you mean Word Perfect ?
 Wordperfect-8.0 used to run on FreeBSD 3.4-RELEASE  was free,
 while Corel charged for the MS based version !

 If I recall correctly, this was a Linux version which ran with Linux
 compatibility as it was then.  Also it only ran with a GUI - the command
 line version was available for $$$.

 I have no idea whether it could be persuaded (easily) to run with recent
 Linux compatibility.

I was checking with google and found
http://tldp.org/FAQ/WordPerfect-Linux-FAQ/downloadwp8.html.  Most of the
links are dead or changed, but a couple of them do have files to
download.
-- 
Carl Johnsonca...@peak.org

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


Re: glabel causes GEOM: ada1: media size does not match label messages

2011-03-20 Thread Carl Johnson
Maxim Khitrov m...@mxcrypt.com writes:

 On Sun, Mar 20, 2011 at 4:38 PM, Maxim Khitrov m...@mxcrypt.com wrote:
 Hi all,

 Executing the following commands on any valid storage device seems to
 cause media size does not match label kernel messages (FreeBSD 8.2
 amd64). I understand why they happen - glabel metadata occupies the
 last sector, so bsdlabel sees a device that is 1 sector smaller than
 what the kernel sees. The question is whether there is some simple way
 of suppressing these messages, since they come up every time the
 system is booted or the partition is mounted/unmounted:

 # glabel label vol0 ada1
 # bsdlabel -w /dev/label/vol0
 GEOM: ada1: media size does not match label.
 # newfs /dev/label/vol0a
 # mount /dev/label/vol0a /mnt
 GEOM: ada1: media size does not match label.
 # umount /mnt
 GEOM: ada1: media size does not match label.

 As you can see, I'm not using MBR or GPT partitioning schemes. I try
 to avoid those unless I plan on sharing the media with another OS.
 Even if using gpart would get rid of these errors (not sure, since
 then you'll just have a partition whose size doesn't match), I would
 still prefer to find some other way to suppress them.

 - Max

  I am not an expert, but that looks correct as you have it, so I would
expect some other problem.  You are using vol0 as the partition for
newfs and its size should be correctly sized to allow for the last
sector of ada1 being used by glabel.  I have heard comments that there
problems in what some call 'dangerously dedicated' partitions, so you
might want to create a single slice covering the whole disk and
partition that.
  If you just want volume names for a filesystem, you might want to try
the -L option for either newfs or tunefs.  The last example of the
glabel manpage shows using a ufs label to contrast it with glabel.  I
use ufs labels for all of my filesystems and just use glabel for swap,
and I suspect that swapon wouldn't catch the type of problem that you
are seeing.

 Heh... In the process of searching for a solution to this, I decided
 to see what would happen if I used bsdlabel on ada1 rather than vol0
 (in my example above), and created a 1-sector partition at the very
 end of the disk. So the layout would be something like this:

 # /dev/ada1:
 8 partitions:
 #size   offsetfstype   [fsize bsize bps/cpg]
   a:**4.2BSD
   c:*0unused
   h:1*unused

 The 'c' partition now covers the entire disk, which stops the kernel
 from complaining about media size not matching the label. At the same
 time, the 'h' partition will protect the last sector, which contains
 glabel metadata.

 The problem now is that the label is technically invalid for the vol0
 device, which is what I'll be mounting. Indeed, bsdlabel complains
 when I run it for /dev/label/vol0:

 # /dev/label/vol0:
 8 partitions:
 #size   offsetfstype   [fsize bsize bps/cpg]
   a: 3907029151   164.2BSD0 0 0
   c: 39070291680unused0 0
   h:1 3907029167unused0 0
 partition c: partition extends past end of unit
 bsdlabel: partition c doesn't cover the whole unit!
 bsdlabel: An incorrect partition c may cause problems for standard
 system utilities
 partition h: partition extends past end of unit

 I don't care about partition 'h'; it is there only to stop the
 preceding partition from covering the last sector. Are there any real
 issues with the 'c' partition being 1 sector too big for the vol0
 device (but just the right size for ada1)?

 This is a bit of a hack, but I'll take it if it stops the kernel from
 complaining and doesn't create any new problems.

I don't see where adding an extra partition at the end does anything to
protect the earlier partition.
-- 
Carl Johnsonca...@peak.org
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Purchased Binaries

2011-03-06 Thread Carl Johnson
Doug Hardie bc...@lafn.org writes:

 I have a client who has purchased some software.  I don't know
 anything much about it yet other than it claims to run on Debian and
 CentOS.  I suspect its binaries.  I will have access to things like
 the developer, name etc. on Monday.  However, thats when he needs to
 know if I can make it run on FreeBSD. I am not convinced I want to run
 production software on the Linux compatibility suite.  No good reason
 other than it sounds like its adding a lot more opportunities for
 breakage.  This has to be an always up application.  I have virtually
 no knowledge of CentOS other than it was installed on one server when
 I got it.  Any chance those binaries might work on FreeBSD?  I am
 planning on starting with FreeBSD 8.2 since its just out and working
 fine on one of my servers, but could use an earlier version if
 required to make this stuff run.

One addition to the points that others have made is that the Linux
compatibility layer appears to be 32 bits only, even for 64 bit versions
of FreeBSD.  At least that is true for Release 8.1.  If the software is
64 bit linux, then it won't work.

-- 
Carl Johnsonca...@peak.org
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Redux

2011-02-14 Thread Carl Johnson
Rem P Roberti remeg...@comcast.net writes:


 To tell the truth, I'm content to leave things as they are, but
 unfortunately one of the side effects of all this is that I can't
 figure out how create and entry in the fstab which will again allow me
 to mount my other hard drive.  The former fstab entry for that was:

 /dev/ad1s1  /c  ntfsrw  1   0

 But now with labels active I really don't know how to proceed.

You can tell what the current labels are with the command 'glabel
status', or 'glabel list' will give a much more detailed listing.
-- 
Carl Johnsonca...@peak.org

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


Re: Debian GNU/kFreeBSD

2011-02-13 Thread Carl Johnson
Odhiambo Washington odhia...@gmail.com writes:

 My question is: WHY need 7 DVDs??? DVDs?? Even M$ does not do such a crazy
 thing with its bloat-ware!! FreeBSD ships 1 DVD.
 What is it that this Debian GNU/kFreeBSD ships in those 7 DVDs?

They contain all packages for that architecture.  They are the
equivalent of the binary packages for the entire FreeBSD ports tree.
You don't need them if you install over the net.
-- 
Carl Johnsonca...@peak.org

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


Re: troubles rebuilding extensions.ini

2011-01-22 Thread Carl Johnson
Gary Kline kl...@thought.org writes:

 On Sat, Jan 22, 2011 at 06:43:23AM +0100, Polytropon wrote:
 On Fri, 21 Jan 2011 22:57:07 -0500, Chris Brennan xa...@xaerolimit.net 
 wrote:
  make rmconfig will remove/reset the config to factory default, then make
  config to restart fresh.
 
 And make rmconfig-recursive will do so for any other port
 the current port depends on. A very handy solution if the
 trouble hides in a dependency of a dependency... :-)
 
 Just see man ports for a list of all targets.
 

   Ye Gods.  The ports manpage is almost unreadable.  Not to
   mention full of non-ASCII bytes.  I'm beat.  Throwing in the
   towel for now.  --Everything works except my own web server.
   Thanks to the list ... and that's it for now.

It should not have any non-ASCII characters, or at least not properly
displayable ones.  That probably means that you have the wrong locale
set for whatever your display is.  If you just want to see only ASCII,
then try 'LANG=C man ports'.  If that doesn't work then try setting
LC_ALL=C instead of LANG=C.

-- 
Carl Johnsonca...@peak.org

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


Re: httpd-modsec2_debug.log: Operation not permitted

2011-01-15 Thread Carl Johnson
Swe Gill sweg...@gmail.com writes:

 Hi Peg

 Thanks for your help by applying ls -lao. I get following result

 -rw---   1 root  wheelsappnd  8307655937 Jan 13 10:45 debug.log
 -rw---   1 root  wheelsappnd   15415 Oct  2  2009 dmesg.today
 -rw-r--r--   1 root  wheel-0 Oct  2  2009
 httpd-access.log
 -rw-r--r--   1 root  wheel-  271 Oct  2  2009
 httpd-error.log
 -rw-rw   1 root  wheel-  53969161077 Jan 13 10:45
 httpd-modsec2_audit.log
 -rw-rw   1 root  wheel-   3397158201 Jan 13 10:44
 httpd-modsec2_debug.log
 -rw-r--r--   1 root  wheelsappnd   28056 Oct  2  2009 lastlog
 -rw-r--r--   1 root  wheelsappnd  66 Oct  1  2009 lpd-errs

 I just don't understand why I am unable to remove the files...

I don't know if you have resolved this yet, but one problem is the
sappnd flag on some of the files.  That flag means that those file are
append-only and can't be deleted or truncated.  You need to remove the
sappnd flag with the command 'chflags nosappnd' for those files.  I
don't think that is default, so somebody had to have manually set the
flag on those files.  Whoever did that should have noted that, or didn't
understand what the operation meant.

-- 
Carl Johnsonca...@peak.org

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


Re: Date of a FreeBSD installation

2011-01-14 Thread Carl Johnson
Chip Camden sterl...@camdensoftware.com writes:

 Quoth Carl Chave on Friday, 14 January 2011:
  I'd suggest looking at the Btimes of top level directories
 
  stat -f %SB %N /*
 
 Or how about just / as this ~15 minutes earlier than most of the
 remaining top level directories
 
 
 sodserve# stat -f %SB %N /*
 Jan  9 04:54:21 2011 /COPYRIGHT
 Jan  9 04:54:21 2011 /bin
 Jan  9 04:54:21 2011 /boot
 Dec 31 18:59:59 1969 /dev
 Jan  9 04:54:21 2011 /etc
 Jan  9 04:54:21 2011 /lib
 Jan  9 04:54:21 2011 /libexec
 Jan  9 04:54:21 2011 /media
 Jan  9 04:54:21 2011 /mnt
 Jan  9 04:54:21 2011 /proc
 Jan  9 04:54:21 2011 /rescue
 Jan  9 04:54:21 2011 /root
 Jan  9 04:54:21 2011 /sbin
 Jan  9 04:54:21 2011 /sys
 Jan  9 04:48:39 2011 /tmp
 Jan  9 04:48:45 2011 /usr
 Jan  9 04:49:39 2011 /var
 
 sodserve# stat -f %SB %N /
 Jan  9 04:39:59 2011 /

 For me, that gets the Nov 21 2009 date, which is earlier than my
 install date.

 So far, /etc/hostid and the /home symlink seem to be the winners.

On my system /etc/hostid is several days later than my actual install
date, so that isn't always reliable.  You might want to create a file
with the timestamp you want.  The most likely time appears to me to be
the 'Created' time in /etc/rc.conf, as someone suggested earlier.  The
following code will extract that and create a file with that timestamp.
I have checked it on my system, but use at your own risk.

file=/etc/install_date
date=$(grep '^# Created: ' /etc/rc.conf | cut -c 12-80)
tdate=$(date -j -f %a %b %d %H:%M:%S %Y $date +%Y%m%d%H%M.%S)
echo $date  $file
touch -t $tdate $file
chmod -w $file
chflags schange $file

-- 
Carl Johnsonca...@peak.org

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


Re: Date of a FreeBSD installation

2011-01-13 Thread Carl Johnson
Polytropon free...@edvax.de writes:

 On Thu, 13 Jan 2011 13:50:27 -0800, Chuck Swiger cswi...@mac.com wrote:
 On Jan 13, 2011, at 1:46 PM, Devin Teske wrote:
  This is nearly always accurate on any FreeBSD system (when wanting to
  query the date the machine was built):
  
 ls -l /etc/defaults/rc.conf
 
 I gather that you don't ever run mergemaster, which would update this file?
 My machine installed in 2001 has a Dec 2010 date for that file:
 
 -r--r--r--  1 root  wheel  36037 Dec  1 14:13 /etc/defaults/rc.conf

 Exactly that was my thought. Maybe a file that is NOT subject
 to one of the system upgrade procedures would be better? Maybe
 something in /boot?

 % ls -l /etc/defaults/rc.conf
 -r--r--r--  1 root  wheel  34300 Aug 24  2008 /etc/defaults/rc.conf
 % ls -l /boot/defaults/loader.conf
 -r--r--r--  1 root  wheel  19426 Aug 24  2008 /boot/defaults/loader.conf

 No, forget about that, also nonsense, looks to new...

How about /var/empty:

% ls -ldo /var/empty/
dr-xr-xr-x  2 root  wheel  schg 512 Jul 18 19:16 /var/empty/

It can be changed, but doesn't look likely.

-- 
Carl Johnsonca...@peak.org

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


Re: Date of a FreeBSD installation

2011-01-13 Thread Carl Johnson
Chip Camden sterl...@camdensoftware.com writes:

 Quoth Carl Johnson on Thursday, 13 January 2011:
 Polytropon free...@edvax.de writes:
 
  On Thu, 13 Jan 2011 13:50:27 -0800, Chuck Swiger cswi...@mac.com wrote:
  On Jan 13, 2011, at 1:46 PM, Devin Teske wrote:
   This is nearly always accurate on any FreeBSD system (when wanting to
   query the date the machine was built):
   
   ls -l /etc/defaults/rc.conf
  
  I gather that you don't ever run mergemaster, which would update this 
  file?
  My machine installed in 2001 has a Dec 2010 date for that file:
  
  -r--r--r--  1 root  wheel  36037 Dec  1 14:13 /etc/defaults/rc.conf
 
  Exactly that was my thought. Maybe a file that is NOT subject
  to one of the system upgrade procedures would be better? Maybe
  something in /boot?
 
  % ls -l /etc/defaults/rc.conf
  -r--r--r--  1 root  wheel  34300 Aug 24  2008 /etc/defaults/rc.conf
  % ls -l /boot/defaults/loader.conf
  -r--r--r--  1 root  wheel  19426 Aug 24  2008 /boot/defaults/loader.conf
 
  No, forget about that, also nonsense, looks to new...
 
 How about /var/empty:
 
 % ls -ldo /var/empty/
 dr-xr-xr-x  2 root  wheel  schg 512 Jul 18 19:16 /var/empty/
 
 It can be changed, but doesn't look likely.

 On my system, it gives a date several months in advance of my install
 date (Nov 21 2009).

Oops, you're right.  I just checked and it is a few days before I
actually installed mine, so that is probably when the ISO was built.

-- 
Carl Johnsonca...@peak.org

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


Re: Simple command to reset / clear all logs?

2011-01-13 Thread Carl Johnson
Polytropon free...@edvax.de writes:

 On Thu, 13 Jan 2011 20:11:03 -0600, Adam Vande More amvandem...@gmail.com 
 wrote:
 Amusing, but you're the one full of shit.  There's more things to automatic
 log file creation than are thought of in your imagination.

 Adam,

 I think Robert is right at least in regards of SOME
 programs that use syslogd for logging OR do the
 logging stuff on their own.

I think that newsyslog will create the new log files if specified in the
/etc/newsyslog.conf file.  That might be the confusion about some log
files being created automatically but others not.  The newsyslog.conf(5)
manpage mentions a 'C' flag that can be specified.

-- 
Carl Johnsonca...@peak.org

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


Re: cpio misunderstanding?

2010-12-26 Thread Carl Johnson
Polytropon free...@edvax.de writes:

 On Sun, 26 Dec 2010 11:30:59 -0800, David Brodbeck g...@gull.us wrote:
 On Fri, Dec 24, 2010 at 4:57 PM, Joe Kraft jvk-l...@thekrafts.org wrote:
  OK, now I know what's going on.  I just don't know why.  The immutable flag
  was set on all these files, if you clear it cpio will happily copy them to
  the new directory.
 
 Does cpio attempt to preserve flags?  Since the error is could not
 create, I'm wondering if it's trying to set the same flags on the
 copy of the file and failing to do so.

 I'm not sure about that - man cpio doesn't give a hint
 about flags. On the other hand, tar's -p option does keep
 the file mode (permissions), flags and maybe ACLs intact.

 I've tried info cpio ouch! ouch!, but that's not a
 continuous manual that allows easy searching for strings. :-(

 Some search in the /usr/src/bin subtree for the chflags
 call revealed that it is used by the chflags binary, cp,
 mv and rm commands, but no hint it is involved directly
 in cpio.

I had done some testing for flag support out of curiosity, and found
that only cp -p, bsdtar and dump support them.  Cpio, afio, gnutar,
gnucp and pax do not support them.  I also tested extended attributes
(used for ACLs?), and only bsdtar and dump worked for them.  Those
results were for usf, and generally didn't transfer to zfs at all or
probably other file systems.

-- 
Carl Johnsonca...@peak.org

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


Re: start kde in 8.1

2010-10-28 Thread Carl Johnson
Tim Dunphy bluethu...@gmail.com writes:

 sorry forgot to mention I am running it on a dell optiplex gx620 ..
 thanks in advance

 On Thu, Oct 28, 2010 at 11:16 PM, Tim Dunphy bluethu...@gmail.com wrote:
 hey guys,
 I have kdebase4 installed successfully under freebsd 8.1
 I found the following advice on the net with so far isn't working to start 
 it:
 echo startkde  ~/.xinitrc
 I have attempted startx but the system doesn't know about it.
 may I have a suggestion to proceed?

Do you have /usr/local/kde4/bin in your path?

-- 
Carl Johnsonca...@peak.org

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


Re: No Sound FBSD 8.1

2010-10-09 Thread Carl Johnson
Scott Ballantyne s...@ssr.com writes:

 Hi Frank,

 You write:
 
 Just a guess, but does:
 
 # sysctl hw.snd.default_unit=1
 
 help?
 
 If so, you can set it permanently in /etc/sysctl.conf
 

 Yes it does, and *thank* *you*. However, it only works with earphones,
 not speakers. Any idea what I can do about that?

 And... do you have the time to explain why the default pcm0 channel
 *doesn't* work?

You can also use 'mixer -f /dev/mixer1' for testing.  On my system
/dev/mixer1 (default_unit=1) controls the back panel jacks, and
/dev/mixer2 controls the front panel headphone jack.  You will probably
have to just experiment with the different mixer controls to see which
controls which on your system.

-- 
Carl Johnsonca...@peak.org

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


Re: extra open ports in rkhunter

2010-09-20 Thread Carl Johnson
Carl Johnson ca...@peak.org writes:

 I am running rkhunter and it keeps reporting a port inconsistency
 between sockstat and netstat -a.  Netstat shows an extra 5 ports open,
 but netstat doesn't show what is holding ports open, so I don't know
 what they are.  Does anybody know how to determine what is holding open
 a port?  I have been looking around but none of my ideas show anything.
 This is a full desktop system with KDE4 and VirtualBox running, so it
 has a lot of things running.  The following are the ports if anybody has
 any ideas, but I would also like to know how to trace them down myself:
 tcp4   0  0 *.876  *.*LISTEN
 tcp6   0  0 *.921  *.*LISTEN
 udp4   0  0 *.608  *.*
 udp6   0  0 *.952  *.*
 udp6   0  0 *.804  *.*

I did some further testing after getting some prompting from an off-list
email.  It turns out that all of those come from rpc.lockd, and that
they are not fixed but change after every restart of rpc.lockd.  I
confirmed this with a fresh install from
FreeBSD-8.1-RELEASE-amd64-dvd1.iso into VirtualBox with networking
disabled.  I also verified the checksums of the .iso to be sure that
nothing had been tampered with.  I had just been trying out nfs but
didn't find anything that I couldn't handle with ssh, so I have since
disabled NFS and all rpc daemons.

Unlisted ports should be useless, so something else must handle those
addresses, probably rpcbind or maybe rpc.statd.  It does seem odd that
rpc.statd has port addresses that show up in sockstat and others, but
rpc.lockd does not.  I never did find anthing that will show many of
those hidden ports.  Nmap will show open ports for tcp4 and tcp6, but
it is too slow for upd4 and doesn't handle udp6 at all.  Nmap also
doesn't identify who has opened ports except by standard addresses, so
that can't identify daemons that dynamically assign their addresses.

Thanks for all of the suggestions.
-- 
Carl Johnsonca...@peak.org

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


Re: extra open ports in rkhunter

2010-09-19 Thread Carl Johnson
Carl Johnson ca...@peak.org writes:

 Anonymous swel...@gmail.com writes:
 Do you have some networking FS enabled (NFS, AFS, Coda, etc)? Perhaps,
 one of them listens for connections from kernel and is not associated
 with userland process. But it's just a guess.

 I have NFS enabled, but its processes are accounted for by both sockstat
 and netstat.

I decided to check out your idea anyways today, and it appears you were
right.  I disabled and stopped all NFS and rpc processes and those extra
ports disappeared from the netstat listing.  None of those ports are
listed as related to anything, so I don't know what is going on.  I had
just experimented with NFS for a while, so I will just leave it off.

Thanks for your suggestion.

-- 
Carl Johnsonca...@peak.org

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


extra open ports in rkhunter

2010-09-18 Thread Carl Johnson
I am running rkhunter and it keeps reporting a port inconsistency
between sockstat and netstat -a.  Netstat shows an extra 5 ports open,
but netstat doesn't show what is holding ports open, so I don't know
what they are.  Does anybody know how to determine what is holding open
a port?  I have been looking around but none of my ideas show anything.
This is a full desktop system with KDE4 and VirtualBox running, so it
has a lot of things running.  The following are the ports if anybody has
any ideas, but I would also like to know how to trace them down myself:
tcp4   0  0 *.876  *.*LISTEN
tcp6   0  0 *.921  *.*LISTEN
udp4   0  0 *.608  *.*
udp6   0  0 *.952  *.*
udp6   0  0 *.804  *.*
-- 
Carl Johnsonca...@peak.org

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


Re: extra open ports in rkhunter

2010-09-18 Thread Carl Johnson
Chuck Swiger cswi...@mac.com writes:

 Hi--

 On Sep 18, 2010, at 4:27 PM, Carl Johnson wrote:
 The following are the ports if anybody has any ideas, but I would also like 
 to know how to trace them down myself:
 
 tcp4   0  0 *.876  *.*LISTEN
 tcp6   0  0 *.921  *.*LISTEN
 udp4   0  0 *.608  *.*
 udp6   0  0 *.952  *.*
 udp6   0  0 *.804  *.*

 Try:

   lsof -i tcp:876

 ...and so forth for the other ports; this will give you the process ID of 
 whatever is holding that socket.

lsof -i doesn't show any of those five ports.  It seems to show the same
ones as sockstat.  I should have mentioned previously that I verified
the tcp ports were open with nmap, but that wouldn't tell me what they
were.  I haven't figured out how to even verify the udp ports are
connected or open.  I also should have mentioned that I don't have any
reason to think that my system is infected, but I just wanted to
understand the difference.

Thanks for the reply.  I had completely forgotten about lsof.

-- 
Carl Johnsonca...@peak.org

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


Re: extra open ports in rkhunter

2010-09-18 Thread Carl Johnson
Anonymous swel...@gmail.com writes:

 Chuck Swiger cswi...@mac.com writes:

 Hi--

 On Sep 18, 2010, at 4:27 PM, Carl Johnson wrote:
 The following are the ports if anybody has any ideas, but I would also like 
 to know how to trace them down myself:
 
 tcp4   0  0 *.876  *.*LISTEN
 tcp6   0  0 *.921  *.*LISTEN
 udp4   0  0 *.608  *.*
 udp6   0  0 *.952  *.*
 udp6   0  0 *.804  *.*

 Do you have some networking FS enabled (NFS, AFS, Coda, etc)? Perhaps,
 one of them listens for connections from kernel and is not associated
 with userland process. But it's just a guess.

I have NFS enabled, but its processes are accounted for by both sockstat
and netstat.

 Speaking of processes, procstat(1) can show them, too.

Procstat seems to show the same ports as sockstat and doesn't show any
of the extra ports that netstat does.

Thanks for the reply.
-- 
Carl Johnsonca...@peak.org

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


Re: fetchmail ssl certificate verification problem in FreeBSD 8.1

2010-08-30 Thread Carl Johnson
Dan Strick mla_str...@att.net writes:

 I just installed FreeBSD release 8.1 and rebuilt the fetchmail port.
 Now I get messages like these when I run fetchmail:

--- snip ---

 I can get rid of the message by removing the ssl option from the user
 line but then fetchmail would not even try to use ssl.  Why would the
 old fetchmail be better able to verify the server's ssl certificate?
 Has openssl changed?  Where is the openssl certificate directory and why
 should the information needed to verify the server's certificate be
 found on my machine?  Doesn't the openssl library contain something
 like a hardwired list of well known certificate authority systems?

You already got replies about using the sslcertfile option pointing to
/usr/local/share/certs/ca-root-nss.crt.  The problem is that only fixes
fetchmail and must be duplicated for each application.  I finally got
around to looking into how to integrate those certificates into the
openssl configuration for FreeBSD, and the following is what I came up
with.

The openssl configuration in /etc/ssl/openssl.cnf expects all
certificates and hashes to be in /etc/ssl/certs, so the certificate file
must be split into individual certificates there, and hashes generated.
The following steps will handle that.  Some of these steps must be
performed as root, so all of them might as well be.


cd /etc/ssl/certs  # create if necessary
split -p '^Certificate:' /usr/local/share/certs/ca-root-nss.crt cert
rm certaa  # just the file header
for file in cert* ; do mv $file $file.pem ; done   # rename to certxx.pem
perl /usr/src/crypto/openssl/tools/c_rehash  . # generate the hashes


The above steps are for a FreeBSD 8.1-RELEASE, so they might not work
exactly for other versions.  This also assumes that you trust the
certificates in the ca_root_nss package, so you will have to decide that
for yourself.

I have seen several questions and problems about ssl certificates, so
hopefully others will find this useful.

-- 
Carl Johnsonca...@peak.org

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


Re: Gnus issue in FreeBSD (was: Re: IPv6 rtadv on FreeBSD 8.1?)

2010-08-08 Thread Carl Johnson
ash...@freebsd.org (Ashish SHUKLA) writes:

 Carl Johnson writes:

 [...]


 Now if I could just figure out why gnus doesn't work right under emacs
 I could finish migrating from Linux to FreeBSD.

 I use same .gnus in both GNU/Linux and FreeBSD and keep the mailboxen on the
 $HOME of both boxen sync-ed with each other, and works great for me.

I posted that in another thread and replied later when I discovered
the problem.  It appears that I had somehow put gnus-agent in offline
mode, so it worked once I realized that and put it back online.

How do you sync the mailboxes together?  That sounds like something
that could be useful for my configuration.  Actually I am trying to
move my old mail from Linux to FreeBSD, but syncing might be an easier
way to handle moving it.

-- 
Carl Johnsonca...@peak.org

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


Re: Gnus issue in FreeBSD

2010-08-08 Thread Carl Johnson
ash...@freebsd.org (Ashish SHUKLA) writes:

 Carl Johnson writes:

...

 I use following sh script to synchronize my mailbox stuff which includes
 Maildirs, Gnus configuration, procmail configuration, mairix db, etc.

...

Thanks, I'll have to think about that.
-- 
Carl Johnsonca...@peak.org

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


Re: Emacs gnus in 8.1 not reading email

2010-08-08 Thread Carl Johnson
ash...@freebsd.org (Ashish SHUKLA) writes:

 Carl Johnson writes:
 Anonymous swel...@gmail.com writes:
...

 Try without ~/.newsrc.eld. BTW, what backend do you use for reading mail?
 nnmaildir?

 I just tried it, but there was no difference.  I use nnml for the
 backend, but that is the same for my other test and normal systems.
 Thanks for the suggestion anyways.

 So, Gnus is not able to read from mail spool, i.e. /var/mail/$USER, right ?
 Can you post your .gnus ?

The problem was that I somehow got into the agent unplugged mode, but
everything started working when I figured that out.  I previously
posted a little more information as a response to my original post, so
that should be in the archives.

Thanks for your reply.
-- 
Carl Johnsonca...@peak.org

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


Re: Emacs gnus in 8.1 not reading email

2010-08-04 Thread Carl Johnson
Carl Johnson ca...@peak.org writes:

 I am experimenting with 8.1 in VirtualBox, but I discovered that I
 can't get gnus to work.  I just brought over my configuration from a
 working 7.3 system, but on 8.1 it won't read the mail from the
 system.  Gnus will start up, but it just reports that there is no
 mail.  It did work one time with a couple of test messages, but I have
 never gotten it to repeat since then.

 I tried sending a couple of messages and they show up in my system
 mailbox.  I also tried reading my system mail with the command line
 mail program and emacs rmail to verify that the system is handling
 mail properly.  I also tried using a blank .gnus file and there was no
 change.  I verified with my 7.3 system that gnus will at least read
 mail with a blank .gnus file.

 Does anybody have any suggestions on what is different?  I have been
 using gnus for many years and I don't really want to change to another
 mail program.  Thanks for any ideas.

I finally stumbled upon the problem, and it was not with FreeBSD (or
emacs).  I discovered that gnus won't check any mail when gnus-agent
is in the unplugged state, even though I just use a local mailbox.  I
must have clicked on the menu item without noticing or know what it
was.  In my defense, the previous version of emacs that I had been
using didn't have or didn't use agent mode, so I had never encountered
it.

Sorry of misleading anybody and thanks for the responses.

-- 
Carl Johnsonca...@peak.org

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


Re: IPv6 rtadv on FreeBSD 8.1?

2010-08-01 Thread Carl Johnson
Carl Johnson ca...@peak.org writes:

 I have running versions of 7.3 and 8.0, so I tried experimenting with
 8.1 in VirtualBox, but I ran into a couple of problems.  I have an 8.0
 system that is running a IPv6 tunnel to sixxs.net, and it is running
 rtadvd to act as the gatway for my network.  On the 8.1 system I
 enabled IPv6 in rc.conf, but it is not picking up the advertised
 address.  I can add it manually, and have put it in rc.local for now,
 but it seems it should work automatically as my others do.  I noticed
 that the ifconfig output shows a new line that is not in 8.0:
 nd6 options=3PERFORMNUD,ACCEPT_RTADV

 Is there something that has changed in 8.1 that I have to enable, or
 is there a problem with 8.1?  IPv6 is working to the extent that it
 did assign a link-local address, and I can use that address as long as
 I specify the interface.  My configuration is the same, and I didn't
 have to enable anything on the others to get the global address
 assigned automatically.

This is a followup to note that it does work when I run it on native
hardware instead of under VirtualBox.  My version of VirtualBox is an
old one (2.1.4) running under Linux, so maybe it has some bugs. I had
installed FreeBSD under VirtualBox, but installed to a primary
partition specifically so that I could later boot directly into it.
The odd thing is that I have a similar FreeBSD 7.3 installation which
does work properly under VirtualBox.

Now if I could just figure out why gnus doesn't work right under emacs
I could finish migrating from Linux to FreeBSD.
-- 
Carl Johnsonca...@peak.org

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


Re: Emacs gnus in 8.1 not reading email

2010-07-31 Thread Carl Johnson
Anonymous swel...@gmail.com writes:

 Carl Johnson ca...@peak.org writes:

 I am experimenting with 8.1 in VirtualBox, but I discovered that I
 can't get gnus to work.  I just brought over my configuration from a
 working 7.3 system, but on 8.1 it won't read the mail from the
 system.  Gnus will start up, but it just reports that there is no
 mail.  It did work one time with a couple of test messages, but I have
 never gotten it to repeat since then.

 I tried sending a couple of messages and they show up in my system
 mailbox.  I also tried reading my system mail with the command line
 mail program and emacs rmail to verify that the system is handling
 mail properly.  I also tried using a blank .gnus file and there was no
 change.  I verified with my 7.3 system that gnus will at least read
 mail with a blank .gnus file.

 Try without ~/.newsrc.eld. BTW, what backend do you use for reading mail?
 nnmaildir?

I just tried it, but there was no difference.  I use nnml for the
backend, but that is the same for my other test and normal systems.
Thanks for the suggestion anyways.

-- 
Carl Johnsonca...@peak.org

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


Emacs gnus in 8.1 not reading email

2010-07-30 Thread Carl Johnson
I am experimenting with 8.1 in VirtualBox, but I discovered that I
can't get gnus to work.  I just brought over my configuration from a
working 7.3 system, but on 8.1 it won't read the mail from the
system.  Gnus will start up, but it just reports that there is no
mail.  It did work one time with a couple of test messages, but I have
never gotten it to repeat since then.

I tried sending a couple of messages and they show up in my system
mailbox.  I also tried reading my system mail with the command line
mail program and emacs rmail to verify that the system is handling
mail properly.  I also tried using a blank .gnus file and there was no
change.  I verified with my 7.3 system that gnus will at least read
mail with a blank .gnus file.

Does anybody have any suggestions on what is different?  I have been
using gnus for many years and I don't really want to change to another
mail program.  Thanks for any ideas.
-- 
Carl Johnsonca...@peak.org

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


IPv6 rtadv on FreeBSD 8.1?

2010-07-30 Thread Carl Johnson
I have running versions of 7.3 and 8.0, so I tried experimenting with
8.1 in VirtualBox, but I ran into a couple of problems.  I have an 8.0
system that is running a IPv6 tunnel to sixxs.net, and it is running
rtadvd to act as the gatway for my network.  On the 8.1 system I
enabled IPv6 in rc.conf, but it is not picking up the advertised
address.  I can add it manually, and have put it in rc.local for now,
but it seems it should work automatically as my others do.  I noticed
that the ifconfig output shows a new line that is not in 8.0:
nd6 options=3PERFORMNUD,ACCEPT_RTADV

Is there something that has changed in 8.1 that I have to enable, or
is there a problem with 8.1?  IPv6 is working to the extent that it
did assign a link-local address, and I can use that address as long as
I specify the interface.  My configuration is the same, and I didn't
have to enable anything on the others to get the global address
assigned automatically.

Thanks for any advice.
-- 
Carl Johnsonca...@peak.org

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


Re: IPv6 rtadv on FreeBSD 8.1?

2010-07-30 Thread Carl Johnson
Vincent Hoffman vi...@unsane.co.uk writes:

 On 30/07/2010 18:48, Carl Johnson wrote:
 I have running versions of 7.3 and 8.0, so I tried experimenting with
 8.1 in VirtualBox, but I ran into a couple of problems.  I have an 8.0
 system that is running a IPv6 tunnel to sixxs.net, and it is running
 rtadvd to act as the gatway for my network.  On the 8.1 system I
 enabled IPv6 in rc.conf, but it is not picking up the advertised
 address.  I can add it manually, and have put it in rc.local for now,
 but it seems it should work automatically as my others do.  I noticed
 that the ifconfig output shows a new line that is not in 8.0:
 nd6 options=3PERFORMNUD,ACCEPT_RTADV

 Is there something that has changed in 8.1 that I have to enable, or
 is there a problem with 8.1?  IPv6 is working to the extent that it
 did assign a link-local address, and I can use that address as long as
 I specify the interface.  My configuration is the same, and I didn't
 have to enable anything on the others to get the global address
 assigned automatically.

 Thanks for any advice.
   
 I dont knw if its expected or not but try running
 sysctl net.inet6.ip6.accept_rtadv=1

 (to make it persistent  echo net.inet6.ip6.accept_rtadv=1 
 /etc/sysctl.conf )

I had already checked that and it is enabled by default, but thanks
for the suggestion anyways.  It also turns out that I was wrong about
it working with manual configuration.  I forgot that the automatic
configuration sets up the external routing, and I haven't figured out
how to do that manually.  So it works for my internal network, but
nowhere else.
-- 
Carl Johnsonca...@peak.org

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


Re: Emacs gnus in 8.1 not reading email

2010-07-30 Thread Carl Johnson
Byung-Hee HWANG b...@izb.knu.ac.kr writes:

 Carl Johnson ca...@peak.org writes:

 I am experimenting with 8.1 in VirtualBox, but I discovered that I
 can't get gnus to work.  I just brought over my configuration from a
 working 7.3 system, but on 8.1 it won't read the mail from the
 system.  Gnus will start up, but it just reports that there is no
 mail.  It did work one time with a couple of test messages, but I have
 never gotten it to repeat since then.

 I tried sending a couple of messages and they show up in my system
 mailbox.  I also tried reading my system mail with the command line
 mail program and emacs rmail to verify that the system is handling
 mail properly.  I also tried using a blank .gnus file and there was no
 change.  I verified with my 7.3 system that gnus will at least read
 mail with a blank .gnus file.

 Does anybody have any suggestions on what is different?  I have been
 using gnus for many years and I don't really want to change to another
 mail program.  Thanks for any ideas.

 Hi, i'm on 8.1-RELEASE. There is no problem.

I am also talking about 8.1-RELEASE, so I don't what is causing my
problems then.  I am using amd64, but I don't see how 32 bit vs 64 bit
could be making a difference.  Thanks for your comment.

-- 
Carl Johnsonca...@peak.org

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


Re: Very low sound volume on Lenovo X200

2010-07-11 Thread Carl Johnson
John Levine jo...@iecc.com writes:

 I can't get the sound to play above a whisper on my newish laptop.  It
 has two sound channels, one for internal speakers, one for the plug,
 and it's the same problem for both.  Every software sound control, of
 which there are several, is set to the max.  The hardware is fine, it
 works correctly under Windows (sigh.)

 Here's dmesg's opinion of what it's got.

 hdac0: Intel 82801I High Definition Audio Controller mem 
 0xf262-0xf2623fff irq 17 at device 27.0 on pci0
 hdac0: HDA Driver Revision: 20090624_0136
 hdac0: [ITHREAD]

 I see that the hda driver has a vast array of options, suggesting that
 something is defaulting wrong.  Any suggestions?

 Here's what it's got now, from the pindump:

 hdac0: Dumping AFG cad=0 nid=1 pins:
 hdac0:  nid 22 0x042140f0 as 15 seq  0Headphones  Jack jack  1 loc  4 
 color   Green misc 0
 hdac0:Caps:OUT HP   Sense: 0x7fff
 hdac0:  nid 23 0x61a190f0 as 15 seq  0   Mic  None jack  1 loc 33 
 colorPink misc 0 [DISABLED]
 hdac0:Caps: IN VREF Sense: 0x7fff
 hdac0:  nid 24 0x04a190f0 as 15 seq  0   Mic  Jack jack  1 loc  4 
 colorPink misc 0
 hdac0:Caps: IN VREF Sense: 0x7fff
 hdac0:  nid 25 0x612140f0 as 15 seq  0Headphones  None jack  1 loc 33 
 color   Green misc 0 [DISABLED]
 hdac0:Caps:OUT  Sense: 0x7fff
 hdac0:  nid 26 0x901701f0 as 15 seq  0   Speaker Fixed jack  7 loc 16 
 color Unknown misc 1
 hdac0:Caps:OUTEAPD 
 hdac0:  nid 27 0x40f001f0 as 15 seq  0 Other  None jack  0 loc  0 
 color Unknown misc 1 [DISABLED]
 hdac0:Caps:OUTEAPD 
 hdac0:  nid 28 0x40f001f0 as 15 seq  0 Other  None jack  0 loc  0 
 color Unknown misc 1 [DISABLED]
 hdac0:Caps:OUT 
 hdac0:  nid 29 0x90a601f0 as 15 seq  0   Mic Fixed jack  6 loc 16 
 color Unknown misc 1
 hdac0:Caps: IN 
 hdac0: NumGPIO=4 NumGPO=0 NumGPI=0 GPIWake=0 GPIUnsol=1
 hdac0: GPIO: data=0x enable=0x direction=0x
 hdac0:   wake=0x  unsol=0xsticky=0x

I am by no means an expert, but I had similar problems previously.
Look at /dev and see if you have multiple /dev/mixer* devices.  You
can use the -f option for mixer to specify the individual devices.  I
found that I had to set the controls on the devices that I wasn't even
using.  In my case, it went from almost completely muted to too loud
and was distorting, so I had to reduce some of the settings.  You can
use sysctl hw.snd.default_unit=1' to set the default mixer device to 1
or whichever you want to use.
-- 
Carl Johnsonca...@peak.org

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


Re: KDE post-install steps

2010-07-02 Thread Carl Johnson
Chris Stankevitz chrisstankev...@yahoo.com writes:

 Installation instructions for GNOME and KDE:
  http://www.freebsd.org/gnome/docs/faq2.html#q1
  http://freebsd.kde.org/instructions.php

 GNOME:
  1. cd /usr/ports/x11/gnome2, make install clean
  2. Add 'gnome_enable=YES' to rc.conf

 KDE:
  1. cd /usr/ports/x11/kde4, make install clean
  2. [none listed]

 Q: Does KDE installation have a Step 2?

Others have mentioned ways of enabling KDE4, but I just added the
following two lines to /etc/rc.conf:
  local_startup=/usr/local/etc/rc.d /usr/local/kde4/etc/rc.d
  kdm4_enable=YES

Or you can omit the local_startup line if you do a:
  ln -s /usr/local/kde4/etc/rc.d/kde4 /usr/local/etc/rc.d/

The local_startup wouldn't be necessary if the startup script were put
in /usr/local/etc/rc.d where it should be.
-- 
Carl Johnsonca...@peak.org

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


Re: .sh check for numeric content

2010-06-24 Thread Carl Johnson
vogelke+u...@pobox.com (Karl Vogel) writes:

 On Thu, 24 Jun 2010 09:24:39 +0800, 
 Aiza aiz...@comclark.com said:

 A Receiving a variable from the command line that is suppose to contain
 A numeric values.  How do I code a test to verify the content is numeric?

The script below will work with the Bourne or Korn shell.
Results for 0 1 12 1234 .12 1.234 12.3 1a a1:

  0 is numeric
  1 is numeric
  12 is numeric
  1234 is numeric
  .12 is numeric
  1.234 is numeric
  12.3 is numeric
  1a is NOT numeric
  a1 is NOT numeric

You might want to try testing 123..45.
I tried changing:
if expr $arg : [0-9]*[\.0-9]*$  /dev/null
to:
if expr $arg : [0-9]*\.*[0-9]*$  /dev/null
but it still claims that it is numeric, so *I* must be missing
something.

-- 
Carl Johnsonca...@peak.org

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


Re: .sh check for numeric content

2010-06-24 Thread Carl Johnson
Carl Johnson ca...@peak.org writes:

 vogelke+u...@pobox.com (Karl Vogel) writes:

 On Thu, 24 Jun 2010 09:24:39 +0800, 
 Aiza aiz...@comclark.com said:

 A Receiving a variable from the command line that is suppose to contain
 A numeric values.  How do I code a test to verify the content is numeric?

The script below will work with the Bourne or Korn shell.
Results for 0 1 12 1234 .12 1.234 12.3 1a a1:

  0 is numeric
  1 is numeric
  12 is numeric
  1234 is numeric
  .12 is numeric
  1.234 is numeric
  12.3 is numeric
  1a is NOT numeric
  a1 is NOT numeric

 You might want to try testing 123..45.
 I tried changing:
if expr $arg : [0-9]*[\.0-9]*$  /dev/null
 to:
 if expr $arg : [0-9]*\.*[0-9]*$  /dev/null
 but it still claims that it is numeric, so *I* must be missing
 something.

I just realized that I had a stupid mistake there and should have
used:  
 if expr $arg : [0-9]*\.[0-9]*$  /dev/null

-- 
Carl Johnsonca...@peak.org

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


Re: .sh check for numeric content

2010-06-24 Thread Carl Johnson
Carl Johnson ca...@peak.org writes:

 Carl Johnson ca...@peak.org writes:

 vogelke+u...@pobox.com (Karl Vogel) writes:

 On Thu, 24 Jun 2010 09:24:39 +0800, 
 Aiza aiz...@comclark.com said:

 A Receiving a variable from the command line that is suppose to contain
 A numeric values.  How do I code a test to verify the content is numeric?

The script below will work with the Bourne or Korn shell.
Results for 0 1 12 1234 .12 1.234 12.3 1a a1:

  0 is numeric
  1 is numeric
  12 is numeric
  1234 is numeric
  .12 is numeric
  1.234 is numeric
  12.3 is numeric
  1a is NOT numeric
  a1 is NOT numeric

 You might want to try testing 123..45.
 I tried changing:
if expr $arg : [0-9]*[\.0-9]*$  /dev/null
 to:
 if expr $arg : [0-9]*\.*[0-9]*$  /dev/null
 but it still claims that it is numeric, so *I* must be missing
 something.

 I just realized that I had a stupid mistake there and should have
 used:  
  if expr $arg : [0-9]*\.[0-9]*$  /dev/null
And of course that was another stupid mistake that I didn't test
properly.  I really wanted 0 or 1 decimal points, so I wanted '\.\?',
except that FreeBSD expr doesn't recognize '\?'.  I finally ended up
with the following which seems to work as *I* expected it to work:
if expr $arg : [1-9]*\.\{0,1\}[0-9]*$  /dev/null

-- 
Carl Johnsonca...@peak.org

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


Re: check for numeric content in a shell script (FreeBSD sh)

2010-06-24 Thread Carl Johnson
p...@pair.com writes:

 if expr $arg : [1-9]*\.\{0,1\}[0-9]*$  /dev/null

 That regex considers . a number but not 0.9 (this one seems to
 be due to typo) nor a negative number.

I had been pointing out an error in the regular expression that
someone else had posted, but I obviously didn't do any better.

 I would personally to use egrep or awk (printf %s ${arg} | egrep
 ${regex} [0]) instead of expr.

I would probably just perl for the whole thing, especially seeing the
limitations in trying to use expr.  Thanks for pointing out another
approach.

-- 
Carl Johnsonca...@peak.org

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


Re: Bash lockups

2010-05-28 Thread Carl Johnson
Giorgos Keramidas keram...@ceid.upatras.gr writes:

 On Fri, 21 May 2010 09:30:05 -0700, Carl Johnson ca...@peak.org wrote:
 Giorgos Keramidas keram...@ceid.upatras.gr writes:
 Does this lock-up happen if you leave the shell 'idle' for too long
 over an ssh session?  There may be problems with stateful connection
 tracking between your terminal and the remote shell :-/

 No, I don't think that could be the problem.  I am just using ssh
 between local machines and there is no firewall between them.  It also
 often seems to happen to a shell as I switch away from it to another
 one.  One suspicion is that something is sending a signal to the shell
 as it switches, and bash sometimes doesn't handle that signal
 properly.

 I also should have mentioned that I have been running bash as my
 default shell for years under Linux and have never seen this problem
 there.

 Thanks for the suggestion.

 That's ok.  If you can attach to the bash process with ktrace please try
 to grab a ktrace file from a deadlocked shell.  We may be able to see
 why it gets deadlocked by running kdump(8) on the shell trace file.

 You can run a second shell under ktrace (and hope that the parent
 doesn't deadlock before the traced child shell), by running:

 bash$ ktrace -f bash.trace bash --login

 When you exit from the child shell you can dump ktrace(8) events from
 the bash.trace file with:

 bash$ kdump -f bash.trace  logfile 21

 Looking near the last records dumped in 'logfile' should be quite
 informative if the process is dead-locked or spinning around the same
 code over and over again.

I finally got one after starting ktrace a few days ago.  It is
informative, but it raises as many questions as it answers.  It
basically just wrote out the prompt, *started* to setup for reading
the input and just stopped.  I ran gdb on it and it is stuck looping
somewhere in getenv.  I don't have the system compiled with debugging,
so I have limited information on what it is doing there.  I checked
multiple times, and I also saw getenv running routines such as memset,
strlen, mbrtowc, and wcsnrtombs.

The following is the tail end of the 'kdump -Ef' output:
  67263 bash 61412.013860 GIO   fd 2 wrote 28 bytes
   0x 0d0f 1b5b 316d 5b63 6172 6c6a 4063 6a62 7364 3874 207e 5d24 1b5b  
|...[1m[ca...@cjbsd8t ~]$.[|
   0x001a 6d20  
|m |

  67263 bash 61412.013867 RET   write 28/0x1c
  67263 bash 61412.013874 CALL  sigprocmask(SIG_SETMASK,0x80e133c,0)
  67263 bash 61412.013880 RET   sigprocmask 0

and the following is the similar section of a normal prompt:
  67263 bash 61403.461469 GIO   fd 2 wrote 27 bytes
   0x 0f1b 5b31 6d5b 6361 726c 6a40 636a 6273 6438 7420 7e5d 241b 5b6d  
|..[1m[ca...@cjbsd8t ~]$.[m|
   0x001a 20
| |
  67263 bash 61403.461476 RET   write 27/0x1b
  67263 bash 61403.461483 CALL  sigprocmask(SIG_SETMASK,0x80e133c,0)
  67263 bash 61403.461489 RET   sigprocmask 0
  67263 bash 61403.461497 CALL  sigprocmask(SIG_BLOCK,0,0x80e1e3c)
  67263 bash 61403.461504 RET   sigprocmask 0
  67263 bash 61403.461513 CALL  read(0,0xbfbfd95f,0x1)

I just realized there is an extra CR at the beginning of that prompt
(28 bytes instead of 27) that I don't see elsewhere, but nothing else
before that looks different.  This one is an i368 8.0 release, but I
also have another hung shell in a amd64 7.3 release system in
VirtualBox.  I just checked my other ktrace logs and I found one
other place where that extra CR occurs, but there is no lockup there
and that was my other system.

The following is a section of a backtrace from gdb: 
  #0  0x28308540 in mbrtowc () from /lib/libc.so.7
  #1  0x080c7ce6 in getenv ()
  #2  0x080c1335 in getenv ()
  #3  0x080ae1d4 in getenv ()
  #4  0x080ac4b0 in getenv ()
  #5  0x080ac815 in getenv ()
  #6  0x080c3955 in getenv ()
  #7  0x080c3ac9 in getenv ()
  #8  0x080ac4b0 in getenv ()
  #9  0x080ac815 in getenv ()
  #10 0x080acb6c in getenv ()
  #11 0x080acf55 in getenv ()
  #12 0x08054611 in ?? ()
  #13 0x284a9a80 in ?? ()
  ...
  #67 0x2832cbfd in time () from /lib/libc.so.7

The first few entries change when I let it run for a while, but the
last 8-9 getenv addresses and everything before them remain the same.
There are a total of about 65 backtrace entries this time, some of
which are 0x addresses which seem suspicious.  The backtrace
from the other hung shell is also in getenv, but I didn't have ktrace
running on that one.

I am at the limit of my experience, so does anybody else have any
ideas about what could cause this, or how I could trace it further?  I
am keeping the processes attached to gdb, so I can do further checking
on them if anyone has any other ideas.  Thanks in advance for any
help, and thanks for the help that allowed me to get this far.

-- 
Carl Johnsonca...@peak.org

Re: [#24512320] Re: Apache22 Upgrade Failure

2010-05-22 Thread Carl Johnson
Matthew Seaman m.sea...@infracaninophile.co.uk writes:

 On 22/05/2010 24:01:52, Odhiambo Washington wrote:
 Is someone saying that FreeBSD lists are not hosted on Mailman? Or is the
 list admin on holiday on the space station? Mailman supports regexes for
 blocking, IIRC.

 Check the message headers: the bogus replies to you come direct from
 mpcustomer.com and don't go anywhere FreeBSD mailman.

The problem is they mangle their headers to say that is comes from the
freebsd-questions mailing list.  The real information is elsewhere,
but that requires some extra looking to find it.  They don't seem to
realize that nobody can solve the problem without their help, and they
don't seem at all interested in working on it.

-- 
Carl Johnsonca...@peak.org

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


Re: Playing Ogg Vorbis files with Audacious

2010-05-21 Thread Carl Johnson
Roland Smith rsm...@xs4all.nl writes:

 On Thu, May 20, 2010 at 08:04:58PM -0700, Carl Johnson wrote:
 I just installed the package for the audio player audacious and I
 discovered that it won't recognize ogg vorbis files.  I installed the
 audacious-plugins package, but I don't see any vorbis plugins in the
 file list, so has it been moved to some other port?  

 Make sure your ports tree is up-to-date. Looking at
 ports/multimedia/audacious-plugins/Makefile version 1.74, the Ogg Vorbis input
 plugin _is_ there. But it is off by default.

Thanks, that just occurred to me this morning.  I had installed it as
a package instead of compiling the port, and it never occurred to me
that vorbis wouldn't be included.  I'll just compile the port for the
plugins now.  I think I'll submit a PR suggesting that it is common
enough that it should be included by default.

-- 
Carl Johnsonca...@peak.org

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


Re: Bash lockups

2010-05-21 Thread Carl Johnson
Giorgos Keramidas keram...@ceid.upatras.gr writes:

 On Wed, 19 May 2010 16:14:52 -0700, Carl Johnson ca...@peak.org wrote:
 I have been experimenting with FreeBSD for a while, and I consistently
 get bash lockups at irregular intervals when it is otherwise idle.  By
 lockup, I mean that it stops responding to the keyboard and uses 100%
 CPU.  It will sometimes go for days with no problems, but I had two
 yesterday, and other today.  They have occurred on test systems
 running in VirtualBox and on a real computer, both i386 and amd64
 images, and a mixture of 7.1, 7.3 and 8.0.  They usually seem to
 happen when I am switching tabs in konsole or switching shells in
 screen, but other times I think they happen when I am not even using
 the system.  The only thing I have found I can do is to do a kill -9
 and start a new shell.

 Does this lock-up happen if you leave the shell 'idle' for too long over
 an ssh session?  There may be problems with stateful connection tracking
 between your terminal and the remote shell :-/

No, I don't think that could be the problem.  I am just using ssh
between local machines and there is no firewall between them.  It also
often seems to happen to a shell as I switch away from it to another
one.  One suspicion is that something is sending a signal to the shell
as it switches, and bash sometimes doesn't handle that signal
properly.

I also should have mentioned that I have been running bash as my
default shell for years under Linux and have never seen this problem
there.

Thanks for the suggestion.

-- 
Carl Johnsonca...@peak.org

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


Re: Bash lockups

2010-05-21 Thread Carl Johnson
Giorgos Keramidas keram...@ceid.upatras.gr writes:

 On Fri, 21 May 2010 09:30:05 -0700, Carl Johnson ca...@peak.org wrote:
 Giorgos Keramidas keram...@ceid.upatras.gr writes:
 Does this lock-up happen if you leave the shell 'idle' for too long
 over an ssh session?  There may be problems with stateful connection
 tracking between your terminal and the remote shell :-/

 No, I don't think that could be the problem.  I am just using ssh
 between local machines and there is no firewall between them.  It also
 often seems to happen to a shell as I switch away from it to another
 one.  One suspicion is that something is sending a signal to the shell
 as it switches, and bash sometimes doesn't handle that signal
 properly.

 I also should have mentioned that I have been running bash as my
 default shell for years under Linux and have never seen this problem
 there.

 Thanks for the suggestion.

 That's ok.  If you can attach to the bash process with ktrace please try
 to grab a ktrace file from a deadlocked shell.  We may be able to see
 why it gets deadlocked by running kdump(8) on the shell trace file.

 You can run a second shell under ktrace (and hope that the parent
 doesn't deadlock before the traced child shell), by running:

 bash$ ktrace -f bash.trace bash --login

 When you exit from the child shell you can dump ktrace(8) events from
 the bash.trace file with:

 bash$ kdump -f bash.trace  logfile 21

 Looking near the last records dumped in 'logfile' should be quite
 informative if the process is dead-locked or spinning around the same
 code over and over again.

Thanks for the detailed information.  I have been mostly a linux user,
so this is new for me.  It hasn't been happening very often lately, so
it might be a while now.  I will definitely try to keep any hung
processes around to try your suggestions.

-- 
Carl Johnsonca...@peak.org

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


Re: Bash lockups

2010-05-20 Thread Carl Johnson
vogelke+u...@pobox.com (Karl Vogel) writes:

 On Wed, 19 May 2010 16:14:52 -0700, 
 Carl Johnson ca...@peak.org said:

 C I have been experimenting with FreeBSD for a while, and I consistently
 C get bash lockups at irregular intervals when it is otherwise idle.
 C Does anybody have any suggestings on how I could try to trace this?

1.  Get a process-table list every minute or so via cron.  It might show
something else running or trying to run when you have your lockups.
Try ps -axw -o user,pid,ppid,pgid,tt,start,time,command.

2.  Get the PID of the bash session, and run something like this as root:

pid=12345
k=1
while true; do
truss -p $pid 21 | head -1000  /dir-with-lots-of-space/$k
k=`expr $k + 1`
done

This should break the truss output into 1000-line chunks and let you
clean out the directory before it chews up all your space.  Hopefully
one of the truss files will show something useful after a lockup.

Thanks for the ideas.  I keep several windows with shells open so I
don't want to trace all of them yet.  I don't even know what the
shells are doing when they lock up, so for now I'll just wait until
one locks up and then try truss to see what it is actually doing.
This happens only occasionally, so I will probably have to wait a
while.

I don't know this is actually just a bash problem since I have never
had it happen running on Linux in at least 10 years.
-- 
Carl Johnsonca...@peak.org

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


Playing Ogg Vorbis files with Audacious

2010-05-20 Thread Carl Johnson
I just installed the package for the audio player audacious and I
discovered that it won't recognize ogg vorbis files.  I installed the
audacious-plugins package, but I don't see any vorbis plugins in the
file list, so has it been moved to some other port?  I am running an
amd64 version of 7.3 release, and it's ports system uses audacity
version 2.2.  I tested the .ogg file with ogg123 and the file is good.

Thanks for any information on how I can get this to work.
-- 
Carl Johnsonca...@peak.org

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


Bash lockups

2010-05-19 Thread Carl Johnson
I have been experimenting with FreeBSD for a while, and I consistently
get bash lockups at irregular intervals when it is otherwise idle.  By
lockup, I mean that it stops responding to the keyboard and uses 100%
CPU.  It will sometimes go for days with no problems, but I had two
yesterday, and other today.  They have occurred on test systems
running in VirtualBox and on a real computer, both i386 and amd64
images, and a mixture of 7.1, 7.3 and 8.0.  They usually seem to
happen when I am switching tabs in konsole or switching shells in
screen, but other times I think they happen when I am not even using
the system.  The only thing I have found I can do is to do a kill -9
and start a new shell.

Does anybody have any suggestings on how I could try to trace this?  I
haven't been able to find any bug reports, but I don't know enough to
know how to search the FreeBSD problem reports very well.

Thanks for any help.  I already subscribe to this list, so there is no
need to cc me.
-- 
Carl Johnsonca...@peak.org

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


Re: glabel nor tunefs save my labels

2010-05-12 Thread Carl Johnson
Roland Smith rsm...@xs4all.nl writes:

 On Tue, May 11, 2010 at 07:46:57PM +0200, David DEMELIER wrote:
 2010/5/11 Roland Smith rsm...@xs4all.nl:
  On Tue, May 11, 2010 at 07:08:40PM +0200, David DEMELIER wrote:
  Thanks for all your answers.
 
  mark...@melon ~ $ sudo tunefs -p /dev/ad0s1f
  snip
  tunefs: volume label: (-L)                                 usr
 
  It's weird, as you can see the label is set but nothing in /dev/label,
  /dev/ufs, /dev/vol !
 
 
 Aaah ! So I understand everything now ! Is this written somewhere ?

 See §19.6 (Labeling Disk Devices) in the FreeBSD Handbook. However, it is not 
 mentioned
 there that labels are removed when the partition is mounted. Maybe that
 behavior is recent?

I am not the original poster, but I tried again and I now am mostly
using labels and the labels are still showing in /dev/ufs/.  I didn't
have labels showing in /dev/ufs, but I changed fstab to what they
should be and rebooted.  The system came up using the labels and they
are showing in /dev/ufs/ and using 'glabel status'.

I say mostly because the /usr partition isn't recognized for some
reason, even though dumpfs and tunefs show the label.  That label is
also not shown in /dev/ufs or using 'glabel status'.  That made the
reboot a little tricky since I had to manually mount /usr in order to
get an editor to edit fstab to continue the boot.

-- 
Carl Johnsonca...@peak.org

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


Re: glabel nor tunefs save my labels

2010-05-12 Thread Carl Johnson
Roland Smith rsm...@xs4all.nl writes:

 On Wed, May 12, 2010 at 09:35:08AM -0700, Carl Johnson wrote:
 Roland Smith rsm...@xs4all.nl writes:
 
  On Tue, May 11, 2010 at 07:46:57PM +0200, David DEMELIER wrote:
  2010/5/11 Roland Smith rsm...@xs4all.nl:
   On Tue, May 11, 2010 at 07:08:40PM +0200, David DEMELIER wrote:
   Thanks for all your answers.
  
   mark...@melon ~ $ sudo tunefs -p /dev/ad0s1f
   snip
   tunefs: volume label: (-L)                                 usr
  
   It's weird, as you can see the label is set but nothing in /dev/label,
   /dev/ufs, /dev/vol !
  
  
  Aaah ! So I understand everything now ! Is this written somewhere ?
 
  See §19.6 (Labeling Disk Devices) in the FreeBSD Handbook. However, it is 
  not mentioned
  there that labels are removed when the partition is mounted. Maybe that
  behavior is recent?
 
 I am not the original poster, but I tried again and I now am mostly
 using labels and the labels are still showing in /dev/ufs/.  I didn't
 have labels showing in /dev/ufs, but I changed fstab to what they
 should be and rebooted.  The system came up using the labels and they
 are showing in /dev/ufs/ and using 'glabel status'.

 When I did my testing, I did not reboot the system. Maybe that is
 the difference?

It might be, but I had rebooted more than once previously.  This time
I mounted them using the labels, so maybe *that* is the difference.  I
have another system running in VirtualBox from Linux (this one is not
a virtual machine) and I don't remember having any similar problems
with labels on it.  It doesn't make sense to me so I really don't
know.

 I say mostly because the /usr partition isn't recognized for some
 reason, even though dumpfs and tunefs show the label.  That label is
 also not shown in /dev/ufs or using 'glabel status'.  That made the
 reboot a little tricky since I had to manually mount /usr in order to
 get an editor to edit fstab to continue the boot.

 That is odd indeed. Maybe a misspelling in the label? Anything in dmesg or
 /var/log/messages.

I have checked many times and can't find anything different about that
FS compared with the others.  It isn't a misspelling because there
isn't anything in /dev/ufs except the other 4 labels that I am already
using.  There is nothing in the logs except the boot error in dmesg
when it couldn't find /usr to mount it.

The system works so I am not really worried about it.  It just
irritates me when I can't get things to work as I think they should.
-- 
Carl Johnsonca...@peak.org

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


Re: glabel nor tunefs save my labels

2010-05-10 Thread Carl Johnson
Demelier David demelier.da...@gmail.com writes:

 On Mon, May 10, 2010 at 11:08:30PM +0200, Roland Smith wrote:
 On Mon, May 10, 2010 at 10:26:18PM +0200, Demelier David wrote:
  Hi,
 I was trying to follow this guide to make labels :
 
  http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/geom-glabel.html
  
 It does not work here, I boot single user and ran these commands :
 glabel label usr /dev/ad0s1f
 
 Do not use this on an already existing filesystem! Use tunefs instead;
 
 tunefs ‐L usr /dev/ad0s1f

You can check to see if it is actually set with:
  dumpfs /dev/ad0s1f | grep volname

I have a similar problem with an 8.0 system in which all partitions
are labeled (and verified from a live CD), but nothing shows in
/dev/ufs, and glabel status shows no labels.

-- 
Carl Johnsonca...@peak.org

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


Re: How to determine /dev/ad* from mount label

2010-04-26 Thread Carl Johnson
Mark G. mark-fbsd-quest-10+20100...@giovannetti.ca writes:

 Hi,

 I've tried the mount, tunefs and df manuals, and don't know
 where to look next.

 I am trying to find out what device, in terms of /dev/ad0s1a
 and so on, is actually 'connected' to a label mounted file
 system.  Here is my fstab (from PC-BSD, by the way):

 # more /etc/fstab
 # Device  Mountpoint   FStype  Options Dump Pass
 /dev/label/rootfs0  /  ufs rw,noatime  1   1
 /dev/label/swap0none   swapsw  0   0
 /dev/label/var0 /var   ufs rw,noatime  1   1
 /dev/label/usr0 /usr   ufs rw,noatime  1   1
 procfs  /proc  procfs  rw  0   0
 linprocfs   /compat/linux/proc linprocfs rw0   0
 tmpfs   /tmp   tmpfs   rw,mode=17770   0

 I just wanted to know if there was a utility to tell me
 which actual device was mounted.  I also tried camcontrol devlist
 and atacontrol list.  The latter allowed me to determine that
 /dev/label/rootfs0 is ad2s1a based on the actual disk size
 and a process of elimination.

 Does anyone know a magic incantation to output this label-device
 mapping?

Try looking at glabel(8).  I don't know what option will list which is
mounted, but 'glabel status' shows the names and what partitions they
are associated with.
-- 
Carl Johnsonca...@peak.org

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


Re: parsing terminfo entries

2010-04-21 Thread Carl Johnson
Robert Huff roberth...@rcn.com writes:

   Other than curses, is there a library that will let me parse a
 terminfo string?  I.e. ask for the value of a particular setting?

I don't know of any way to parse it, but have you looked at tput(1)?
It will give the value of termcap or terminfo attributes for any
terminal type that you specify.
-- 
Carl Johnsonca...@peak.org

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


Re: slow clock on FreeBSD 7.2 on vmware

2009-12-12 Thread Carl Johnson
Robert Fitzpatrick li...@webtent.net writes:

 On 12/12/2009 12:59 PM, andrew clarke wrote:
 On Sat 2009-12-12 12:06:18 UTC-0500, Robert Fitzpatrick (rob...@webtent.com) 
 wrote:


 pgsql# cat /boot/loader.conf
 kern.ipc.semmni=32
 kern.ipc.semmns=512
 hint.apic.0.disabled=1
  
 According to the loader.conf man page these should all be in the format:

 kern.ipc.semmni=32
 kern.ipc.semmns=512
 hint.apic.0.disabled=1

 I don't know if this matters.

 I'm not sure hint.apic.0.disabled is valid for 7.2.  sysctl -a doesn't
 list this variable on my machine.  Maybe it's only available on some
 machines.


 The only way I'm able to keep the clock up to date is to sync with
 an Internet time server regularly. Anyone have an idea how fix this
 issue?
  
 Can you use ntpd?

 Regards
 Andrew


 I'm pulling from a time server now every hour, keeps it from getting
 behind too much. Perhaps that is what I'll end up doing, loading the
 ntp server, I guess that would keep it up to date better? Thanks.

If it is consistently off by a certain amount, then you might want to
look into /usr/sbin/ntptime to set a frequency offset.  If it works,
then you can put it into somewhere like /etc/rc.local.

-- 
Carl Johnsonca...@peak.org


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


  1   2   >