Re: IPC Shared memory segment

2013-03-20 Thread Vagner
The solution was given at revision 233760.
Link for description:
http://svnweb.freebsd.org/base?view=revisionrevision=233760
Thanks to all!

-- 
Respectfully,
Stanislav Putrya
System administrator
FotoStrana.Ru Ltd.
ICQ IM: 328585847
Jabber-GoogleTalk: root.vagner
mob.phone SPB: +79215788755
mob.phone RND: +79525600664
email: vag...@bsdway.ru
email: put...@playform.ru
email: root.vag...@gmail.com
site: bsdway.ru
site: fotostrana.ru


 ( ) ASCII ribbon campaign
  X  - against HTML, vCards and
 / \ - proprietary attachments in e-mail
___
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


IPC Shared memory segment

2013-03-19 Thread Vagner
Hi all!
Tell me please, how may I remove shared memory segment like this:

T:m shmid:65537 shmkey:0 mode:--rw-rw-rw- owner:root group:wheel creator:root 
cgroup:wheel
NATTCH:2 SEGSZ:1048576000 CPID:2982 LPID:54375 ATIME:10:29:12 DTIME:15:56:14 
CTIME:10:51:00

Pid 2982 and pid 54375 is killed.

-- 
Respectfully,
Stanislav Putrya
System administrator
FotoStrana.Ru Ltd.
ICQ IM: 328585847
Jabber-GoogleTalk: root.vagner
mob.phone SPB: +79215788755
mob.phone RND: +79525600664
email: vag...@bsdway.ru
email: put...@playform.ru
email: root.vag...@gmail.com
site: bsdway.ru
site: fotostrana.ru


 ( ) ASCII ribbon campaign
  X  - against HTML, vCards and
 / \ - proprietary attachments in e-mail
___
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: IPC Shared memory segment

2013-03-19 Thread Julien Cigar

On 03/19/2013 13:06, Vagner wrote:

Hi all!
Tell me please, how may I remove shared memory segment like this:

T:m shmid:65537 shmkey:0 mode:--rw-rw-rw- owner:root group:wheel creator:root 
cgroup:wheel
NATTCH:2 SEGSZ:1048576000 CPID:2982 LPID:54375 ATIME:10:29:12 DTIME:15:56:14 
CTIME:10:51:00

Pid 2982 and pid 54375 is killed.



man ipcrm

--
No trees were killed in the creation of this message.
However, many electrons were terribly inconvenienced.

___
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


Linux app shared memory problem

2012-08-12 Thread Per olof Ljungmark
Trying to run a Linux app under 9-STABLE. I can start it once and stop 
it once but all subsequent efforts produces a core dump.


I believe the reason being that this app stores licensing information in 
shared memory and when it stops first time it fails to remove this info.


Is there a sysctl parameter that would be useful in a case like this?

Thanks,
___
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: Linux app shared memory problem

2012-08-12 Thread Per olof Ljungmark

On 08/12/12 11:12, Per olof Ljungmark wrote:

Trying to run a Linux app under 9-STABLE. I can start it once and stop
it once but all subsequent efforts produces a core dump.

I believe the reason being that this app stores licensing information in
shared memory and when it stops first time it fails to remove this info.

Is there a sysctl parameter that would be useful in a case like this?



Additional info:

linux_set_robust_list(0x2820c710,0xc,0x2808fff4,0x2820c6c0,0x0,0x6) = 0 
(0x0)

linux_sys_futex(0xcc90,0x81,0x1,0x2820c6c0,0x2808fff4,0x6) = 0 (0x0)
linux_rt_sigaction(0x20,0xc948,0x0,0x8,0x2808fff4,0x6) = 0 (0x0)
linux_rt_sigaction(0x21,0xc948,0x0,0x8,0x2808fff4,0x6) = 0 (0x0)
linux_rt_sigprocmask(0x1,0xcbfc,0x0,0x8,0x2808fff4,0x6) = 0 (0x0)
linux_getrlimit(0x3,0xcc84,0x28207ff4,0x10,0x1,0x6) = 0 (0x0)
linux_newuname(0xc9f8,0x2820b400,0x2808fff4,0x0,0xc9f8,0x6) = 0 
(0x0)

linux_ipc(0x17,0x4f524553,0x1,0x3ff,0x0,0x6) = 65536 (0x1)
linux_ipc(0x15,0x1,0x0,0xcbe8,0x0,0x6)   = 0 (0x0)
linux_ipc(0x2,0x4f726583,0x1,0x1ff,0x0,0x6)  ERR#13 'Permission denied'
linux_ipc(0x3,0x,0x0,0x10c,0xca68,0x6) ERR#22 'Invalid argument'
linux_rt_sigaction(0xe,0xc9c8,0x0,0x8,0x2808fff4,0x6) = 0 (0x0)
linux_alarm(0x14,0x0,0x80589d8,0xcb10,0xcb94,0x6) = 0 (0x0)
linux_ipc(0x1,0x,0x1,0x0,0xcba0,0x6) ERR#22 'Invalid argument'
linux_rt_sigaction(0xe,0xc9c8,0x0,0x8,0x2808fff4,0x6) = 0 (0x0)
linux_alarm(0x0,0x0,0x80589d8,0x,0xcba0,0x6) = 20 (0x14)
linux_ipc(0x3,0x,0x0,0x10c,0xca88,0x6) ERR#22 'Invalid argument'
linux_rt_sigaction(0xe,0xc9e8,0x0,0x8,0x2808fff4,0x6) = 0 (0x0)
linux_alarm(0x14,0x0,0x80589d8,0xcb30,0xcbb4,0x6) = 0 (0x0)
linux_ipc(0x1,0x,0x1,0x0,0xcbc0,0x6) ERR#22 'Invalid argument'
linux_rt_sigaction(0xe,0xc9e8,0x0,0x8,0x2808fff4,0x6) = 0 (0x0)
linux_alarm(0x0,0x0,0x80589d8,0x,0xcbc0,0x6) = 20 (0x14)
linux_fstat64(0x1,0xcaf4,0x28207ff4,0x282084c0,0x282084c0,0x6) = 0 (0x0)
linux_mmap2(0x0,0x1000,0x3,0x22,0x,0x6)  = 671576064 (0x28077000)
Shared memory problem
___
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: Apache FCGI in a a jail under FBSD 9 won't start due to shared memory creation error

2012-08-11 Thread Chad Leigh Shire.Net LLC

On Aug 9, 2012, at 9:41 AM, Fbsd8 wrote:

 Chad Leigh Shire.Net LLC wrote:
 On Aug 7, 2012, at 10:31 AM, Mark Felder wrote:
 jail_sysvipc_allow=YES in rc.conf should do it.
 Hmm
 I added that and rebooted the jail host system. However, the setting in 
 sysctl security.jail.sysvipc_allowed  is still 0 after the reboot
 # sysctl -a | grep sysvipc
 security.jail.param.allow.sysvipc: 0
 security.jail.sysvipc_allowed: 0
 #
 I can set security.jail.sysvipc_allowed to 1 manually.  However, even after 
 doing that, the original fcgi problem happens when starting apache2.2 with 
 mod_fcgid in the configuration and being loaded
 [Tue Aug 07 13:09:12 2012] [emerg] (78)Function not implemented: mod_fcgid: 
 Can't create shared memory for size 1192488 bytes
 Thanks!
 Chad
 Since you manually installed apache22 and mod_fcgid from up-stream sources 
 maybe you missed something. As a test create another jail and install the 
 package versions of apache22 and mod_fcgid and see if that will start ok. If 
 it does them you know you missed something in your hand job version.
 


Hi

Thanks for the suggestion.  I don't think, however, that anything is missing 
with my from-source compilations. I have been running self-compiled apaches for 
15 years and have also done mod_fcgid in the past as well without issue (but 
not inside a jail).  I don't think it is a matter of sw missing, but of system 
parameters or similar.'

Thanks
Chad



Re: Apache FCGI in a a jail under FBSD 9 won't start due to shared memory creation error

2012-08-09 Thread Fbsd8

Chad Leigh Shire.Net LLC wrote:

On Aug 7, 2012, at 10:31 AM, Mark Felder wrote:


jail_sysvipc_allow=YES in rc.conf should do it.


Hmm

I added that and rebooted the jail host system. However, the setting in sysctl 


security.jail.sysvipc_allowed  is still 0 after the reboot

# sysctl -a | grep sysvipc
security.jail.param.allow.sysvipc: 0
security.jail.sysvipc_allowed: 0
#

I can set security.jail.sysvipc_allowed to 1 manually.  However, even after 
doing that, the original fcgi problem happens when starting apache2.2 with 
mod_fcgid in the configuration and being loaded

[Tue Aug 07 13:09:12 2012] [emerg] (78)Function not implemented: mod_fcgid: 
Can't create shared memory for size 1192488 bytes


Thanks!
Chad


Since you manually installed apache22 and mod_fcgid from up-stream 
sources maybe you missed something. As a test create another jail and 
install the package versions of apache22 and mod_fcgid and see if that 
will start ok. If it does them you know you missed something in your 
hand job version.



___
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


Apache FCGI in a a jail under FBSD 9 won't start due to shared memory creation error

2012-08-07 Thread Chad Leigh Shire . Net LLC
Hi.  I'll try this again.

I run systems using FreeBSD 9.0

FreeBSD utah.XXXcom 9.0-STABLE FreeBSD 9.0-STABLE #1: Wed Mar 21 15:22:14 
MDT 2012 chad@underhill:/usr/obj/usr/src/sys/UNDERHILL-XEN  amd64

and on those systems run a bunch of jails.  I have Apache 2.2 built and running 
in the jail in question, and recently had need to add mod_fcgid to it.  NOTE 
that the Apache and mod_fcgid were not installed through ports or packages.  I 
download the source and build myself (for various reasons).  

Apache inside the Jail, with mod_fcgid enabled will not start:

[Mon Jul 23 10:59:35 2012] [emerg] (78)Function not implemented: mod_fcgid: 
Can't create shared memory for size 1192488 bytes


I did a search on this and found that I would probably need a system kernel 
parameter changed from 0 - 1

security.jail.sysvipc_allowed

So I did that.  (And restarted the jail).  However, I still get the same error 
when trying to start apache.

I noticed a similar parameter  security.jail.param.allow.sysvipc  but cannot 
change this at run time and did not find anything useful about what this 
parameter is for using a search engine.

(As an aside, how would I change security.jail.sysvipc_allowed   and also 
security.jail.param.allow.sysvipc at boot time?  I added them both to 
/boot/loader.conf but they did not get changed at boot and I had to do the 
security.jail.sysvipc_allowed one again on the command line -- I have some vfs 
type kernel state variables set there and they stick)

I would appreciate some help with getting things set up so that I can run 
apache with mod_fcgid under my Jails on FBSD 9.

Thanks!
Chad



Re: Apache FCGI in a a jail under FBSD 9 won't start due to shared memory creation error

2012-08-07 Thread Mark Felder

jail_sysvipc_allow=YES in rc.conf should do it.
___
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: Apache FCGI in a a jail under FBSD 9 won't start due to shared memory creation error

2012-08-07 Thread Chad Leigh Shire.Net LLC

On Aug 7, 2012, at 10:31 AM, Mark Felder wrote:

 jail_sysvipc_allow=YES in rc.conf should do it.

Hmm

I added that and rebooted the jail host system. However, the setting in sysctl 

security.jail.sysvipc_allowed  is still 0 after the reboot

# sysctl -a | grep sysvipc
security.jail.param.allow.sysvipc: 0
security.jail.sysvipc_allowed: 0
#

I can set security.jail.sysvipc_allowed to 1 manually.  However, even after 
doing that, the original fcgi problem happens when starting apache2.2 with 
mod_fcgid in the configuration and being loaded

[Tue Aug 07 13:09:12 2012] [emerg] (78)Function not implemented: mod_fcgid: 
Can't create shared memory for size 1192488 bytes


Thanks!
Chad




Apache FCGI in a a jail under FBSD 9 won't start due to shared memory creation error

2012-07-27 Thread Chad Leigh Shire . Net LLC
Hi

I run systems using FreeBSD 9.0

FreeBSD utah.XXXcom 9.0-STABLE FreeBSD 9.0-STABLE #1: Wed Mar 21 15:22:14 
MDT 2012 chad@underhill:/usr/obj/usr/src/sys/UNDERHILL-XEN  amd64

and on those systems run a bunch of jails.  I have Apache 2.2 built and running 
in the jail in question, and recently had need to add mod_fcgid to it.  NOTE 
that the Apache and mod_fcgid were not installed through ports or packages.  I 
download the source and build myself (for various reasons).  

Apache inside the Jail, with mod_fcgid enabled will not start:

[Mon Jul 23 10:59:35 2012] [emerg] (78)Function not implemented: mod_fcgid: 
Can't create shared memory for size 1192488 bytes


I did a search on this and found that I would probably need a system kernel 
parameter changed from 0 - 1

security.jail.sysvipc_allowed

So I did that.  (And restarted the jail).  However, I still get the same error 
when trying to start apache.

I noticed a similar parameter  security.jail.param.allow.sysvipc  but cannot 
change this at run time and did not find anything useful about what this 
parameter is for using a search engine.

(As an aside, how would I change security.jail.sysvipc_allowed   and also 
security.jail.param.allow.sysvipc at boot time?  I added them both to 
/boot/loader.conf but they did not get changed at boot and I had to do the 
security.jail.sysvipc_allowed one again on the command line -- I have some vfs 
type kernel state variables set there and they stick)

I would appreciate some help with getting things set up so that I can run 
apache with mod_fcgid under my Jails on FBSD 9.

Thanks!
Chad


___
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


Shared Memory allocation in jail

2012-01-05 Thread bsd
Hi, 

I am trying to run both postgres and zabbix in the same jail and I am only able 
to start postgres or zabbix not both of them. 

I have tuned my sysctl on master host as follow : 

kern.ipc.shmmax=268435456
kern.ipc.shmall=409600
kern.ipc.semmap=256

security.jail.allow_raw_sockets=1
security.jail.sysvipc_allowed=1
security.jail.enforce_statfs=1


No special tunning on jail host. 


I have also tunned in rc.conf 
jail_sysvipc_allow=YES



I am still not able to start both at the same time. 


Any idea ? 

––
- Grégory Bernard Director -
--- www.osnet.eu ---
-- Your provider of OpenSource appliances --
––
OSnetOSnetOSnetOSnetOSnetOSnetOSnetOSnetOSnetO

___
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: Shared Memory allocation in jail

2012-01-05 Thread bsd
Le 5 janv. 2012 à 14:56, bsd a écrit :

 Hi, 
 
 I am trying to run both postgres and zabbix in the same jail and I am only 
 able to start postgres or zabbix not both of them. 
 
 I have tuned my sysctl on master host as follow : 
 
 kern.ipc.shmmax=268435456
 kern.ipc.shmall=409600
 kern.ipc.semmap=256
 
 security.jail.allow_raw_sockets=1
 security.jail.sysvipc_allowed=1
 security.jail.enforce_statfs=1
 
 
 No special tunning on jail host. 
 
 
 I have also tunned in rc.conf 
 jail_sysvipc_allow=YES
 
 
 
 I am still not able to start both at the same time. 
 
 
 Any idea ? 

Infos here were helpful : http://www.freebsddiary.org/jail-multiple.php

I have 

• re-configure /boot/loader.conf
• configured sysctl.conf with various options


# rebooted and the issue was solved. 


 
 ––
 - Grégory Bernard Director -
 --- www.osnet.eu ---
 -- Your provider of OpenSource appliances --
 ––
 OSnetOSnetOSnetOSnetOSnetOSnetOSnetOSnetOSnetO
 
 ___
 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


––
- Grégory Bernard Director -
--- www.osnet.eu ---
-- Your provider of OpenSource appliances --
––
OSnetOSnetOSnetOSnetOSnetOSnetOSnetOSnetOSnetO

___
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: Shared Memory allocation in jail

2012-01-05 Thread Alejandro Imass
On Thu, Jan 5, 2012 at 8:56 AM, bsd b...@todoo.biz wrote:
 Hi,

 I am trying to run both postgres and zabbix in the same jail and I am only 
 able to start postgres or zabbix not both of them.



Yeah bro, it bit me in the ass as well ;-) the SysV IPC is common for
the whole system. So anything that uses IPC in jails will have to go
through this process

You have to change the Pg user's id and the chown the Pg files. I use
a nomeclature for this and is the last 3 digits of the jail's IP and
the original uid. Example The jail on 192.168.101.124 has a Pg user of
70124 for port NATing I use the contrary nomenclature like 12480 is
the network port 80 of the same jail in th public IP as 12480.

Anyway here is my recipe:

pw usermod pgsql -u 70124
 pw groupmod pgsql -g 70124
 chown -R pgsql /usr/local/pgsql/
 chgrp -R pgsql /usr/local/pgsql/

When you run ipcs from the jail You should the see something like the
example below, where there is still one Pg on uid 70 but from the
jail's perspective it's the pgsql user who now has uid of 70124

Message Queues:
  T   ID  KEY MODEOWNERGROUP

  Shared Memory:
  T   ID  KEY MODEOWNERGROUP
  m  1179648  5432001 --rw--- 70   70
  m   1310730 --rw--- 70   70
  m  1572866  5432002 --rw--- pgsqlpgsql

  Semaphores:
  T   ID  KEY MODEOWNERGROUP
  s  1703936  5432001 --rw--- 70   70
  s  1703937  5432002 --rw--- 70   70
  s  1703938  5432003 --rw--- 70   70
  s  1572867  5432004 --rw--- 70   70
  s  1572868  5432005 --rw--- 70   70
  s  1572869  5432006 --rw--- 70   70
  s  1572870  5432007 --rw--- 70   70
  s  1179655  5432008 --rw--- pgsqlpgsql
  s  1179656  5432009 --rw--- pgsqlpgsql
  s  1179657  5432010 --rw--- pgsqlpgsql
  s  1179658  5432011 --rw--- pgsqlpgsql
  s  1179659  5432012 --rw--- pgsqlpgsql
  s  1179660  5432013 --rw--- pgsqlpgsql
  s  1179661  5432014 --rw--- pgsqlpgsql

Cheers,

-- 
Alejandro Imass
___
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: Opera: X Shared memory extension is not available. ZPixmap not supported

2009-05-14 Thread Andreas Rudisch
On Thu, 14 May 2009 09:03:25 + (GMT)
Saifi Khan saifi.k...@twincling.org wrote:

 Running Opera 9.64 on X.org 7.4 leads to freeze ups in Opera.
 
 The error reported is
 Opera: X Shared memory extension is not available. ZPixmap not
 supported
 
 My system is  Intel CeleronM 1.6GHz, Intel 945GM mobo.

I get this message too, it is just a note stating a feature of X is
missing to support ZPixmap properly so Opera will not use it.

I have not seen any big problems with Opera for years, so maybe you
have got some faulty hardware or other configuration issues.

Also please try to correct your time / time zone settings, all your
mails are arriving from the future.

Andreas
--
GnuPG key  : 0x2A573565|http://www.gnupg.org/howtos/de/
Fingerprint: 925D 2089 0BF9 8DE5 9166  33BB F0FD CD37 2A57 3565


pgpMqnCp5TrSJ.pgp
Description: PGP signature


Opera: X Shared memory extension is not available. ZPixmap not supported

2009-05-13 Thread Saifi Khan
Hi all:

Running Opera 9.64 on X.org 7.4 leads to freeze ups in Opera.

The error reported is
Opera: X Shared memory extension is not available. ZPixmap not
supported

My system is  Intel CeleronM 1.6GHz, Intel 945GM mobo.

Some of the blogs seem to suggest that the new driver shipped
has fixed the issue. Does anybody know ? Is there a recommended
work around ?


thanks
Saifi.
___
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: PostgreSQL on FreeBSD 7.0 amd64 with more than 2GB shared memory

2008-12-11 Thread Ivan Voras
Hell, Robert wrote:
 I just found a bug report for that issue:
 http://www.freebsd.org/cgi/query-pr.cgi?pr=121423cat=

Try asking on current@ - I think there were some patches available some
time ago.


 -Original Message-
 From: Wojciech Puchar [mailto:[EMAIL PROTECTED] 
 Sent: Mittwoch, 10. Dezember 2008 18:30
 To: Hell, Robert
 Cc: freebsd-questions@freebsd.org
 Subject: Re: PostgreSQL on FreeBSD 7.0 amd64 with more than 2GB shared
 memory
 
 fails again with ENOMEM.
 Is there any easy way to use a shared memory segment which is larger
 than 2GB?
 
 getting two smaller ? :)
 
 no idea - maybe it's bug of SHM. as you already checked it please do 
 sent-pr
 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to [EMAIL PROTECTED]
 



signature.asc
Description: OpenPGP digital signature


PostgreSQL on FreeBSD 7.0 amd64 with more than 2GB shared memory

2008-12-10 Thread Hell, Robert
Hi,

I'm trying to run PostgreSQL 8.3 on a FreeBSD 7.0 amd64 server with more
than 2GB shared memory. The machine has 32GB RAM installed.
After setting kern.ipc.shmmax and kern.ipc.shmall to the appropriate
values, I still had no chance to start postgres with more than 2GB of
shared memory.

I wrote a small test which does the same as postgres: shmget and shmat:
#include sys/ipc.h
#include sys/shm.h
#include stdio.h
#include errno.h

int main()
{
  int shmid, memKey = 1;
  void *memAddress;
  unsigned long size = 2147483648UL;

  shmid = shmget(memKey, size, IPC_CREAT | IPC_EXCL);
  if (shmid  0) {
printf(shmget failed: %d\n, errno);
return 1;
  }

  memAddress = shmat(shmid, NULL, 0);
  if (memAddress == (void *) -1) {
printf(shmat failed: %d\n, errno);
  }

  return 0;
}


I found out that shmget failed with ENOMEM in shmget_allocate_segment
(sysv_shm.c) because of an overflow of size (requested shared memory in
bytes):
int i, segnum, shmid, size;
...
size = round_page(uap-size);
if (shm_committed + btoc(size)  shminfo.shmall) {
return (ENOMEM);
}

When changing size to an unsigned long shmget works - but now shmat then
fails again with ENOMEM.
Is there any easy way to use a shared memory segment which is larger
than 2GB?

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


Re: PostgreSQL on FreeBSD 7.0 amd64 with more than 2GB shared memory

2008-12-10 Thread Wojciech Puchar

fails again with ENOMEM.
Is there any easy way to use a shared memory segment which is larger
than 2GB?


getting two smaller ? :)

no idea - maybe it's bug of SHM. as you already checked it please do 
sent-pr

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


RE: PostgreSQL on FreeBSD 7.0 amd64 with more than 2GB shared memory

2008-12-10 Thread Hell, Robert
I just found a bug report for that issue:
http://www.freebsd.org/cgi/query-pr.cgi?pr=121423cat=

Thanks,
Robert

-Original Message-
From: Wojciech Puchar [mailto:[EMAIL PROTECTED] 
Sent: Mittwoch, 10. Dezember 2008 18:30
To: Hell, Robert
Cc: freebsd-questions@freebsd.org
Subject: Re: PostgreSQL on FreeBSD 7.0 amd64 with more than 2GB shared
memory

 fails again with ENOMEM.
 Is there any easy way to use a shared memory segment which is larger
 than 2GB?

getting two smaller ? :)

no idea - maybe it's bug of SHM. as you already checked it please do 
sent-pr
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


rmuser error - shared memory

2008-02-18 Thread Lubomir Matousek
Thanks very much Bill and James. Hana vs hanka is only typo at this mail
(hana is correct, as it is in my box).
I apologize for this incorrect information.


Bill, you are right, the kernel was build without shared memory support.
Option SYSVSHM is not included in the kernel.

As I cannot recompile the kernel on this production server now, can be there
any impact on instability of my system with missing SYSVSHM option?



-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Bill Moran
Sent: Saturday, February 16, 2008 6:04 PM
To: [EMAIL PROTECTED]
Cc: Lubomir Matousek; freebsd-questions@freebsd.org
Subject: Re: (no subject)

James [EMAIL PROTECTED] wrote:

 
 On Sat, 2008-02-16 at 09:11 +0100, Lubomir Matousek wrote:
  Dear list, 
  
   
  
  I have the following problem when using rmuser (freebsd 6.2)
  
   
  
  --
  
  rmuser -v hana
  
  Matching password entry:
  
   
  
  hana:*:1091:1092::0:0:/usr/home/hana:/usr/sbin/nologin
  
   
  
  Is this the entry you wish to remove? yes Remove user's home directory
  (/usr/home/hanka)? yes Removing crontab for (hana):.
  
  Removing at(1) jobs owned by (hana): 0 removed.
  
  Removing IPC mechanismsipcs: sysctlbyname: kern.ipc.shmmax: No such file
or
  directory
  
  ipcs: sysctlbyname: kern.ipc.shmmax: No such file or directory
  
  ipcs: sysctlbyname: kern.ipc.shmmax: No such file or directory .
  
  Terminating all processes owned by (hana): -KILL signal sent to 0
processes.
  
  Removing files owned by (hana) in /tmp: 0 removed.
  
  Removing files owned by (hana) in /var/tmp: 0 removed.
  
  Removing mail spool(s) for (hana): /var/mail/hana.
  
  Removing user (hana) (including home directory) from the system: Done.
  
  ---
  
   
  
  The problem started, when I accidentaly deleted /usr/home directory and
I
  had to create a new one. I checked /etc/password file and the direcory
  existed before using rmuser. Can anybody help please?
  
   
  
  
  
  Lubos
 
 
 Looks like the problem is that somewhere within there it's expected that
 the home directory isn't /usr/home/hana, it's /usr/home/hanka
 
 Have you checked /etc/master.passwd to make sure that there's no
 mis-entry in there? Or just try creating /usr/home/hanka and see if it
 works itself out.

Personally, I'm unsure where the problem is.  The only suspicious thing
I see is the inability to remove shared memory segments, which is a bit
strange but not wholly unexpected.  Did you build a kernel without shared
memory?

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

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


OT: VIA-EK disabling shared memory

2007-11-19 Thread Erik Norgaard

Hi:

I got a VIA EPIA-EK board which has some advanced settings for graphics, 
you can toggle how much shared memory to allocate for graphics. Nice, 
but my device won't have a display so I'd like not to allocate any.


There is an option for disabling shared memory, but then the system 
won't boot. It hangs and I can't even enter the bios. So, I guess I have 
to find the magic combination with other options.


The manual only lists the options and recommends not to mess with them 
unless you know what you're doing. There is no mention on how to get the 
disable-shared-memory to work.


Any one got a clue?

Thanks, Erik

--
Erik Nørgaard
Ph: +34.666334818   http://www.locolomo.org
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Shared Memory and Xorg.

2007-02-11 Thread Sean Bryant
I tend to visit Opera's Desktop team blog to see what new features are 
going to be in the next release of the Opera browser. And one 
interesting tid-bit was:

Added Shared X memory. Should now be quite a bit faster

And beneath this note was:
Note: On FreeBSD shared memory doesn't work by FreeBSD design. You need 
to run this as as root:

# sysctl kern.ipc.shm_allow_removed=1

What exactly does this mean. And is X shared memory special shared 
memory in anyway?

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


PostgreSQL Shared Memory and Semaphors

2006-10-13 Thread [EMAIL PROTECTED]

Hello,

I want to increase the max_connections of PostgreSQL from around 40 to 
around 100. For this I need to change the Shared Memory and Semaphores 
settings.


I followed this link -

http://www.postgresql.org/docs/8.1/interactive/kernel-resources.html#SYSVIPC

and used the proposed values in a test installation FreeBSD 5.5, 
PostgreSQL 8.x, with 96 MB RAM (a VMware guest) -


I added -

kern.ipc.shmall=32768
kern.ipc.shmmax=134217728
kern.ipc.semmap=256
to /etc/sysctl.conf

kern.ipc.semmni=256
kern.ipc.semmns=512
kern.ipc.semmnu=256
to /boot/loader.conf

And I changed max_connections = 40 to 100 in postgresql.conf.

Rebooted and all works OK.

Now I want to do the same on a production machine FreeBSD 5.4, 
PostgreSQL 8.x, with 2 GB RAM.


Are there any dangers I should have in mind?

Thank you,
Iv

PS I know that the values can be compiled into the kernel, but I am not 
that good yet.

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


Re: Shared Memory?

2006-06-03 Thread Micah

B. Cook wrote:

Hello All,

I'm not a programmer and nor do I play one in real life.. :)

I've recently setup a DansGuardian box for someone and I had some 
interesting things happen.


When the box would get under load (500+ simultaneout connections) it 
would load up the cpu:


last pid: 69931;  load averages:  4.73,  3.56,  3.32  up 5+11:10:58
09:56:31
49 processes:  8 running, 41 sleeping

Mem: 157M Active, 202M Inact, 106M Wired, 20M Cache, 60M Buf, 8168K Free
Swap: 2048M Total, 32K Used, 2048M Free


   PID USERNAME  THR PRI NICE   SIZERES STATETIME   WCPU COMMAND
49814 guardian1 1200 85868K 85160K RUN  0:01 14.87% 
dansguardian
30132 guardian1 1200 85868K 85180K RUN  0:22 14.11% 
dansguardian
52245 guardian1 1190 85860K 85168K RUN  0:06 13.94% 
dansguardian
23445 guardian1 1200 85896K 85208K RUN  0:22 13.87% 
dansguardian


at this time there were 10 dansguardian processes running.  the default 
config suggests 120 to start off with.. (doing that crashed the box in 
about 5 minutes)


I found one thing that seemed to help:
kern.ipc.shm_use_phys=1

from man tuning.

after setting the sysctl value the system now looks like this:
last pid: 40265;  load averages:  0.29,  0.29,  0.27 
  up 
7+17:55:46  16:41:47

34 processes:  1 running, 33 sleeping
CPU states:  0.0% user,  0.0% nice,  0.7% system,  1.5% interrupt, 97.8% 
idle

Mem: 125M Active, 249M Inact, 98M Wired, 16M Cache, 60M Buf, 4392K Free
Swap: 2048M Total, 36K Used, 2048M Free

  PID USERNAME  THR PRI NICE   SIZERES STATETIME   WCPU COMMAND
 6266 guardian1  960 76116K 18004K select   0:05 12.54% 
dansguardian
  696 guardian1  960 76112K 16960K select   0:01  0.81% 
dansguardian
 8969 guardian1  960 76112K  6036K select   0:00  0.12% 
dansguardian

21017 squid   1  960 31228K 26684K select  41:52  0.00% squid

After searching I can't seem to find out when it's appropriate (or not) 
to set this and if anything else should be set in conjunction with it.


Other than the fact that this helped.. can anyone point me in a 
direction or tell me why it helped?


collecting pv entries -- suggest increasing PMAP_SHPGPERPROC
collecting pv entries -- suggest increasing PMAP_SHPGPERPROC

this error is what somewhat lead me to this discovery.  And in hoping to 
fix that it suggested recompling the kernel with those values changed.. 
NOTES tells me that that value is now 201, google has people with 
numbers all over the place.. and I still can't seem to figure out why 
they did it.


egrep -v # /etc/sysctl.conf

security.bsd.see_other_uids=0
net.inet.ip.forwarding=1
net.inet.ip.random_id=1
kern.randompid=1
kern.coredump=0

kern.ipc.shmmax=536870912
kern.ipc.shm_use_phys=1

This is a stock 6.1 GENERIC kernel

The box is a router for internet traffic that passes several gigs of 
data from about 2500+ users.


Its a small 866 w/ 512M of ram and as previously stated running 
DansGuardian (www/dansguardian) and squid (www/squid).


I've asked a few times for information on the DG list, but I guess it's 
mainly a linux only crowd as I did not hear anything back from anyone.


netstat -m
260/2155/2415 mbufs in use (current/cache/total)
258/1264/1522/17088 mbuf clusters in use (current/cache/total/max)
258/1210 mbuf+clusters out of packet secondary zone in use (current/cache)
0/0/0/0 4k (page size) jumbo clusters in use (current/cache/total/max)
0/0/0/0 9k jumbo clusters in use (current/cache/total/max)
0/0/0/0 16k jumbo clusters in use (current/cache/total/max)
581K/3066K/3647K bytes allocated to network (current/cache/total)
56061/494261/470674 requests for mbufs denied 
(mbufs/clusters/mbuf+clusters)

0/0/0 requests for jumbo clusters denied (4k/9k/16k)
0/9/4528 sfbufs in use (current/peak/max)
0 requests for sfbufs denied
0 requests for sfbufs delayed
12 requests for I/O initiated by sendfile
328 calls to protocol drain routines

They want me to move it a larger box just for the sake of putting it on 
a larger box.. (2.2G Xeon w/ 2G ram) but I'd like to tune it better.. as 
opposed to just throw hardware at it and hope for the best.


all data/packets passes over lo..

lo0   16384 127   127.0.0.1 57055828 - 33798613 - -

and the box so far has been up for 7 days.



Any information helping me understand this beast would be greatly 
appreciated.


- Brian


This thread talks a little bit about how to choose an appropriate size 
for PMAP_SHPGPERPROC in regards to Apache - it might be adapted to work 
with DG:

http://lists.freebsd.org/pipermail/freebsd-hackers/2003-May/000695.html

I snooped through the code a little, but am not familiar enough with 
FreeBSD's guts to understand what pv_entries are other than they have 
something to do with paged memory


Hope that link helps some,
Micah
___
freebsd-questions@freebsd.org mailing 

Shared Memory?

2006-06-01 Thread B. Cook

Hello All,

I'm not a programmer and nor do I play one in real life.. :)

I've recently setup a DansGuardian box for someone and I had some 
interesting things happen.


When the box would get under load (500+ simultaneout connections) it 
would load up the cpu:


last pid: 69931;  load averages:  4.73,  3.56,  3.32  up 5+11:10:58
09:56:31
49 processes:  8 running, 41 sleeping

Mem: 157M Active, 202M Inact, 106M Wired, 20M Cache, 60M Buf, 8168K Free
Swap: 2048M Total, 32K Used, 2048M Free


   PID USERNAME  THR PRI NICE   SIZERES STATETIME   WCPU COMMAND
49814 guardian1 1200 85868K 85160K RUN  0:01 14.87% dansguardian
30132 guardian1 1200 85868K 85180K RUN  0:22 14.11% dansguardian
52245 guardian1 1190 85860K 85168K RUN  0:06 13.94% dansguardian
23445 guardian1 1200 85896K 85208K RUN  0:22 13.87% dansguardian

at this time there were 10 dansguardian processes running.  the default 
config suggests 120 to start off with.. (doing that crashed the box in 
about 5 minutes)


I found one thing that seemed to help:
kern.ipc.shm_use_phys=1

from man tuning.

after setting the sysctl value the system now looks like this:
last pid: 40265;  load averages:  0.29,  0.29,  0.27 
  up 
7+17:55:46  16:41:47

34 processes:  1 running, 33 sleeping
CPU states:  0.0% user,  0.0% nice,  0.7% system,  1.5% interrupt, 97.8% 
idle

Mem: 125M Active, 249M Inact, 98M Wired, 16M Cache, 60M Buf, 4392K Free
Swap: 2048M Total, 36K Used, 2048M Free

  PID USERNAME  THR PRI NICE   SIZERES STATETIME   WCPU COMMAND
 6266 guardian1  960 76116K 18004K select   0:05 12.54% 
dansguardian
  696 guardian1  960 76112K 16960K select   0:01  0.81% 
dansguardian
 8969 guardian1  960 76112K  6036K select   0:00  0.12% 
dansguardian

21017 squid   1  960 31228K 26684K select  41:52  0.00% squid

After searching I can't seem to find out when it's appropriate (or not) 
to set this and if anything else should be set in conjunction with it.


Other than the fact that this helped.. can anyone point me in a 
direction or tell me why it helped?


collecting pv entries -- suggest increasing PMAP_SHPGPERPROC
collecting pv entries -- suggest increasing PMAP_SHPGPERPROC

this error is what somewhat lead me to this discovery.  And in hoping to 
fix that it suggested recompling the kernel with those values changed.. 
NOTES tells me that that value is now 201, google has people with 
numbers all over the place.. and I still can't seem to figure out why 
they did it.


egrep -v # /etc/sysctl.conf

security.bsd.see_other_uids=0
net.inet.ip.forwarding=1
net.inet.ip.random_id=1
kern.randompid=1
kern.coredump=0

kern.ipc.shmmax=536870912
kern.ipc.shm_use_phys=1

This is a stock 6.1 GENERIC kernel

The box is a router for internet traffic that passes several gigs of 
data from about 2500+ users.


Its a small 866 w/ 512M of ram and as previously stated running 
DansGuardian (www/dansguardian) and squid (www/squid).


I've asked a few times for information on the DG list, but I guess it's 
mainly a linux only crowd as I did not hear anything back from anyone.


netstat -m
260/2155/2415 mbufs in use (current/cache/total)
258/1264/1522/17088 mbuf clusters in use (current/cache/total/max)
258/1210 mbuf+clusters out of packet secondary zone in use (current/cache)
0/0/0/0 4k (page size) jumbo clusters in use (current/cache/total/max)
0/0/0/0 9k jumbo clusters in use (current/cache/total/max)
0/0/0/0 16k jumbo clusters in use (current/cache/total/max)
581K/3066K/3647K bytes allocated to network (current/cache/total)
56061/494261/470674 requests for mbufs denied (mbufs/clusters/mbuf+clusters)
0/0/0 requests for jumbo clusters denied (4k/9k/16k)
0/9/4528 sfbufs in use (current/peak/max)
0 requests for sfbufs denied
0 requests for sfbufs delayed
12 requests for I/O initiated by sendfile
328 calls to protocol drain routines

They want me to move it a larger box just for the sake of putting it on 
a larger box.. (2.2G Xeon w/ 2G ram) but I'd like to tune it better.. as 
opposed to just throw hardware at it and hope for the best.


all data/packets passes over lo..

lo0   16384 127   127.0.0.1 57055828 - 33798613 
- -


and the box so far has been up for 7 days.



Any information helping me understand this beast would be greatly 
appreciated.


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


Re: shared memory settings in 5.3

2004-12-13 Thread John
  Thank you for the quick reply.  That was very
helpful.  I thought I'd post what I found out for the
next poor knob setting up sybase; 
  The default setting of SHMMAXPGS appears to be 8192.
 Default page size is 4K, which gives you the 33554432
kern.ipc.shmmax value from sysctl.  This means (if my
math is right) you have 32mg of shared memory to allow
sybase to grab.  This is fine for the default sybase
install (7500 2k pgs).  I set 'options
SHMMAXPGS=40960' in my recompiled kernel, which gives
me a kern.ipc.shmmax 160 megs.  This allowd me to set
sybase's 'total memory' at 80,000 (2k pages) giving me
just under 160 megs of memory available for data
caches, which sybase is able to use at great advantage
when the circumstances are right...  
  

J
  
  I have seen references to setting SHMMAXPGS, but
am   not quite
  sure how to set this or what units it is currently
  set in now.
 
 This is set in your kernel configuration file. 
 Check GENERIC and
 NOTES for the default settings.  See the handbook
 for more help on
 building a kernel.





__ 
Do you Yahoo!? 
Yahoo! Mail - Helps protect you from nasty viruses. 
http://promotions.yahoo.com/new_mail
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: shared memory settings in 5.3

2004-12-12 Thread Kris Kennaway
On Sun, Dec 12, 2004 at 01:52:20PM -0800, John wrote:
 Hello,
   I am setting up sybase 11 to run on 5.3 release and
 want to increase the available shared memory for
 sybase to use but am unsure how to do this.  I have
 seen references to setting SHMMAXPGS, but am not quite
 sure how to set this or what units it is currently set
 in now.  Any help would be greatly appreciated. 

This is set in your kernel configuration file.  Check GENERIC and
NOTES for the default settings.  See the handbook for more help on
building a kernel.

Kris


pgpKcR3aM3NJe.pgp
Description: PGP signature


shared memory settings in 5.3

2004-12-12 Thread John
Hello,
  I am setting up sybase 11 to run on 5.3 release and
want to increase the available shared memory for
sybase to use but am unsure how to do this.  I have
seen references to setting SHMMAXPGS, but am not quite
sure how to set this or what units it is currently set
in now.  Any help would be greatly appreciated. 

J




__ 
Do you Yahoo!? 
Yahoo! Mail - Helps protect you from nasty viruses. 
http://promotions.yahoo.com/new_mail
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


shared memory

2004-10-28 Thread Mike Hauber
Greetings,

I have acquired a mo/bo with a built-in video adapter.  
Being that I have 768 megs of ram, I _know_ I have plenty 
of memory to allot to video.  BIOS doesn't pass this on to 
FreeBSD.

I have two choices for x.  I can use the VESA standard or I 
can use the S3 video driver (both come up fine, but theres 
quit a bit of chop when it comes to video processing 
regardless of which I use). 

I'm bringing up VESA from the kernal and it's giving it 16 
megs of ram.  Where can I read up on, or how can I increase 
this allotment?

As for the S3 video driver, do I allot the memory from the 
kernal or is this somehow set up from the x configuration 
file?  (I'm running x.org, although that probably shouldn't 
matter being that they pretty much seem the same at this 
point).

Applicable nfo as follows:

(from dmesg -a)

Timecounter i8254  frequency 1193182 Hz
CPU: AMD Athlon(tm) Processor (1202.73-MHz 686-class CPU)
  Origin = AuthenticAMD  Id = 0x644  Stepping = 4
  Features=0x183f9ffFPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,SEP,MTRR,PGE,MCA,CMOV,PA
T,PSE36,MMX,FXSR
  AMD Features=0xc044RSVD,AMIE,DSP,3DNow!
real memory  = 788463616 (769984K bytes)
avail memory = 760496128 (742672K bytes)
Preloaded elf module vesa.ko at 0xc066d140.
...snip...
VESA: v3.0, 16384k memory, flags:0x1, mode table:0xc00c0e2a 
(ce2a)
VESA: S3 Incorporated. Savage4
...snip...
agp0: VIA 82C8363 (Apollo KT133A) host to PCI bridge mem 
0xd800-0xdbff
 at device 0.0 on pci0
pcib1: VIA 8363 (Apollo KT133) PCI-PCI (AGP) bridge at 
device 1.0 on pci0
pci1: PCI bus on pcib1
pci1: S3 model 8a26 graphics accelerator at 0.0 irq 9
...snip...
sc0: System console at flags 0x100 on isa0
sc0: VGA 16 virtual consoles, flags=0x300
vga0: Generic ISA VGA at port 0x3c0-0x3df iomem 
0xa-0xb on isa0
...snip...


(from /sys/i386/conf/WIZARD, comments removed for cleaner 
reading)

cpu I686_CPU
ident   WIZARD
maxusers132
options CPU_ATHLON_SSE_HACK
options CPU_ENABLE_SSE
...snip...
options USER_LDT
options SHMALL=32768
options SHMMAX=67108864
options VESA
...snip...
device  sc0 at isa? flags 0x100
device  vga0at isa?
device  agp
...snip...


From what I've read on it, I can tell you that I'm 
completely lost when it comes to shared memory (and reading 
more seems to confuse me more).  I simply don't understand 
how it works.  

Of course, I know that built in video is recommended against 
(regardless of what OS is running), but I'm sure there's a 
way to up the memory...  And I hope that theres a place 
that explains how it works in laymens terms?  :)

So far, I've re-read the manual on setting up x, for setting 
up video applications, various video app manuals, LINT, and 
many googles on shared memory.

Mayhaps there's a man page I'm missing that puts all this 
stuff in perspective?  If not, someone explain it so I can 
write one.  :)

Thanks.

Mike

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


Re: shared memory

2004-10-28 Thread Chuck Swiger
Mike Hauber wrote:
I have acquired a mo/bo with a built-in video adapter.  
Being that I have 768 megs of ram, I _know_ I have plenty 
of memory to allot to video.  BIOS doesn't pass this on to 
FreeBSD.
[ ... ]
I'm bringing up VESA from the kernal and it's giving it 16 
megs of ram.  Where can I read up on, or how can I increase 
this allotment?
I think you have an integrated video controller which uses main memory rather 
than having it's own dedicated VRAM.  Look for an option in your BIOS config 
to adjust the size of the frame buffer.

You should adjust the amount of memory reserved for video to enough to handle 
whatever screen depth you want to run at, there isn't much point to allocating 
any more.

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


Re: shared memory

2004-10-28 Thread Mike Hauber
On Thursday 28 October 2004 12:39 pm, Chuck Swiger 
proclaimed:
 Mike Hauber wrote:
  I have acquired a mo/bo with a built-in video adapter.
  Being that I have 768 megs of ram, I _know_ I have
  plenty of memory to allot to video.  BIOS doesn't pass
  this on to FreeBSD.

 [ ... ]

  I'm bringing up VESA from the kernal and it's giving it
  16 megs of ram.  Where can I read up on, or how can I
  increase this allotment?

 I think you have an integrated video controller which
 uses main memory rather than having it's own dedicated
 VRAM.  Look for an option in your BIOS config to adjust
 the size of the frame buffer.

 You should adjust the amount of memory reserved for video
 to enough to handle whatever screen depth you want to run
 at, there isn't much point to allocating any more.

Whoa.  I thought I had tried that, but apparently I didn't 
(or at least I couldn't have saved before restarting).  
Sorry.  FreeBSD _does_ respect the allotment.

Thanks.  That's what I needed (besides a break).

Regards,

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


how to tell how much of shared memory is used?

2004-04-14 Thread Aditya
ipcs -a tells me how much shared memory has been allocated to a process, but
is there a way to tell how much of that allocated space is being used?

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


shared memory release...

2004-03-30 Thread Tim Traver
Hi all,

Ok, I am running a 4.7 FreeBSD box that is a web server running apache.

It looks like some module that I have is leaking memory, and eventually, 
apache crashes on restarts becuase of this error :

shmget() failed:  No space left on device

which means it can't get any more memory, which I understand.

When I look at the top list, it shows me something like this :

Mem: 140M Active, 879M Inact, 151M Wired, 181M Cache, 199M Buf, 660M Free

But when you look at the processes that are still up, they hardly take up 
any memory.

So, my question is this.

Is there a way to free up Inactive memory from crashed processes ???

Without just rebooting the box ???

I know that I need to find the source of the leaking and crashing to begin 
with, but in the mean time, if it happens, I'd like to free up the memory 
manually, so I can get the box running again...

Thanks,

Tim.

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


Re: shared memory release...

2004-03-30 Thread Chuck Swiger
Tim Traver wrote:
Ok, I am running a 4.7 FreeBSD box that is a web server running apache.

It looks like some module that I have is leaking memory, and eventually, 
apache crashes on restarts becuase of this error :

shmget() failed:  No space left on device

which means it can't get any more memory, which I understand.
SysV shared memory is a limited resource which has tunables you need to set or 
adjust in your kernel config file.  It's not the same as physical RAM.

When I look at the top list, it shows me something like this :

Mem: 140M Active, 879M Inact, 151M Wired, 181M Cache, 199M Buf, 660M Free
top is measuring something else, here.

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


2 gig shared memory

2003-03-26 Thread Kim Shrier
I am configuring a dual processor box with 4 gig of memory.  One of the
main applications I will be running is PostgreSQL.  It uses SysV shared
memory for its internal data pages.  If I were to configure a 4.8 kernal
to have 2 gig  of SysV shared memory, will this cause problems.  The
remaining 2 gig of memory is more than sufficient for the rest of the
programs that will be running on the machine.
Kim

--
Kim Shrier - principal, Shrier and Deihl - mailto:[EMAIL PROTECTED]
Remote Unix Network Admin, Security, Internet Software Development
 Tinker Internet Services - Superior FreeBSD-based Web Hosting
http://www.tinker.com/
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: 2 gig shared memory

2003-03-26 Thread Kim Shrier
I will persue the configuration issue on the postgresql lists.  However,
what I was hoping to get an answer for on this list is, will FreeBSD belly
up if I configure 2 gig of SysV shared memory.
Thanks,
Kim
David Bear wrote:

On Wed, Mar 26, 2003 at 04:31:56PM -0600, Kim Shrier wrote:
 

I am configuring a dual processor box with 4 gig of memory.  One of the
main applications I will be running is PostgreSQL.  It uses SysV shared
memory for its internal data pages.  If I were to configure a 4.8 kernal
to have 2 gig  of SysV shared memory, will this cause problems.  The
remaining 2 gig of memory is more than sufficient for the rest of the
programs that will be running on the machine.
   

you really should ask the postgresql users list on this one.  As I
recall there were a set of diminishing returns the kick in as SHMEM
gets big --
 

--
Kim Shrier - principal, Shrier and Deihl - mailto:[EMAIL PROTECTED]
Remote Unix Network Admin, Security, Internet Software Development
 Tinker Internet Services - Superior FreeBSD-based Web Hosting
http://www.tinker.com/
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Apache and shared memory

2003-03-02 Thread Mike Harding

When people talk about optimizing mod_perl shared memory, they are not
referring to System V type shared memory as seen by ipcs.  They are
talking about memory shared by virtue of a process fork - this is
effectively read only memory.  The net effect is that a process may
appear to be 20 meg, but may only use 2 or 3 meg, say.

It has been difficult to monitor 'unshared' memory use in FreeBSD as
freebsd has traditionally reported via getrusage() as an 'integrated'
unshared memory use which is more related to the old school process
accounting than it is to the actual unshared memory use - this may
have changed in -CURRENT or recent -STABLEs.  Linux reports the
unshared memory directly via gtop which is a lot more convenient.  I
wish (hint hint) that there was a sysctl to handle this...

There are other tricks you can do to maximize memory use, such as
putting the php and perl servers, and image servers on separate apache
processes, and proxying between them, rather than running php and
mod_perl on the same server, and adjusting the (Min/Max)SpareServers
to reap apache process during quieter times.

The main thing to do with mod_perl is to pre-load all of the perl
modules during apache startup so that the modules are shared rather
than being loaded separately into each apache process.
http://perl.apache.org has some excellent documentation about this.
Also Apache::SizeLimit can be useful for mod_perl based systems.

Tuning apache can be a lot of... fun!

Hope this helps,

- Mike H.

To Unsubscribe: send mail to [EMAIL PROTECTED]
with unsubscribe freebsd-questions in the body of the message


Apache and shared memory

2003-03-01 Thread Haapanen, Tom
We are running a reasonably busy web site on FreeBSD (100K-200K hits per
day); we have split the database server (MySQL on FreeBSD 4.3) apart from
the web server  (Apache on FreeBSD 5.0 now).  Both running i386 versions
(Athlon CPUs).

Things generally work very well, but ongoing memory usage is a concern.  We
have to run both mod_perl and mod_php, and the resulting memory usage is in
the 10-20 MB range per httpd process.  (The mod_php seems especially leaky
with respect to memory.)  So on our 1 GB web server, it's pretty risky
running more than 50 httpd processes.

I keep reading about optimizing mod_perl shared memory, and yet it seems I
am missing an essential piece, as it looks like the system is not using
shared memory at all:

# ipcs -m 
Shared Memory:
T ID KEYMODE   OWNERGROUP
# sysctl -a | grep shm
kern.ipc.shmmax: 33554432
kern.ipc.shmmin: 1
kern.ipc.shmmni: 192
kern.ipc.shmseg: 128
kern.ipc.shmall: 8192
kern.ipc.shm_use_phys: 0
  shm 116K 16K1  16384
#

This is running with the GENERIC kernel, which appears to have shared memory
enabled.  Using the precompiled Apache 1.3.27 port from freebsd.org.

So it appears that I somehow need to tell Apache that I want to use shared
memory, before I even try to optimize mod_perl.  And yet I can't find any
appropriate directives.

Can anyone suggest what I am missing?  I can only add another 512 MB to the
machine before the add-more-physical-memory approach runs out.

Thanks ...

Tom Haapanen
[EMAIL PROTECTED]

To Unsubscribe: send mail to [EMAIL PROTECTED]
with unsubscribe freebsd-questions in the body of the message