Advertisement:

Author Topic: My server configuration OK?  (Read 20130 times)

Offline Vekseid

  • Full Member
  • ***
  • Posts: 548
  • Gender: Male
    • Elliquiy Adult Role Playing Forums
Re: My server configuration OK?
« Reply #40 on: February 18, 2009, 10:38:01 PM »
I didn't know that about SSL in Apache. Good to know.

Actually I should take that back, that would be if you were using virtualhosts... if you are only using ssl for your main domain and set that up to be apache's default, I think you could actually get away with just one fcgi-php process.

I'm not, however, and currently my little VPS is averaging 4 php calls/second. It handles fine until someone else on the server gets hoggy. But! I just ordered a nice dedicated package... will look to see how nginx performs versus apache in siege tests, I think >_>
Adult Role Playing Forums - - Over five million posts - - Elliquiy's LAMP configuration (maybe NSFW)

Blog about Forums and Servers - - Twenty things to make Simple Machines Forum go faster

Private/Instant Message requests for free support will be ignored.

Offline Tiribulus

  • Sophist Member
  • *****
  • Posts: 1,016
  • Gender: Male
    • Tiribulus on Facebook
    • No Other God
Re: My server configuration OK?
« Reply #41 on: February 19, 2009, 12:15:13 AM »
Clearly, I still have a lot to learn :)

Offline Something like that

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 2,496
  • Gender: Male
  • ]
Re: My server configuration OK?
« Reply #42 on: February 19, 2009, 01:42:56 AM »
Clearly, I still have a lot to learn :)

Experiment. It's the best way.

Offline Tiribulus

  • Sophist Member
  • *****
  • Posts: 1,016
  • Gender: Male
    • Tiribulus on Facebook
    • No Other God
Re: My server configuration OK?
« Reply #43 on: February 19, 2009, 09:04:26 PM »
Am I correct in assuming that 100% fragmentation for APC is bad and I need to adjust something?

http://gregnmary.gotdns.com:8080/apc.php

Offline Something like that

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 2,496
  • Gender: Male
  • ]
Re: My server configuration OK?
« Reply #44 on: February 19, 2009, 09:08:12 PM »
Yes. You're running out of cache space. I'd increase the size of it in php.ini. Try doubling it.

Offline Tiribulus

  • Sophist Member
  • *****
  • Posts: 1,016
  • Gender: Male
    • Tiribulus on Facebook
    • No Other God
Re: My server configuration OK?
« Reply #45 on: February 19, 2009, 09:15:23 PM »
Yes. You're running out of cache space. I'd increase the size of it in php.ini. Try doubling it.

I added these basic settings I found somewhere and restarted Apache which of course reset the cache. Do you see anything that could use improvement? I had nothing except the line to start APC before. I assume shm_size is the cache?

apc.enabled=1                                               # default = 1
apc.shm_segments=1                                   # default = 1
apc.shm_size=128                                        # default = 30
apc.ttl=7200                                                  # default = 0
apc.user_ttl=7200                                         # default = 0
apc.num_files_hint=1024                            # default = 1000
apc.mmap_file_mask=/tmp/apc.XXXXXX   # default = no value
apc.enable_cli=1                                            # default = 0

Offline Something like that

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 2,496
  • Gender: Male
  • ]
Re: My server configuration OK?
« Reply #46 on: February 19, 2009, 09:19:18 PM »
I would adjust the apc.ttl and apc.user_ttl to something like 604800 (one week). There's no sense emptying the cache early.

I'd watch your cache usage and adjust apc.shm_size smaller if the cache mostly sitting empty. :)

Offline Tiribulus

  • Sophist Member
  • *****
  • Posts: 1,016
  • Gender: Male
    • Tiribulus on Facebook
    • No Other God
Re: My server configuration OK?
« Reply #47 on: February 19, 2009, 09:23:26 PM »
Did that, thanks.

So that is the cache size then?

Thanks for your help again btw.

EDIT: Actually, putting those lines in my php.ini right under extension=apc.so file has no effect. The settings are showing the same. hmmmm

EDIT1: Oh yeah, I did restart Apache

EDIT2: I figured out I wasn't supposed to include the default values at the end of each line. Got rid of those, restarted Apache again there the settings are. :-[
« Last Edit: February 19, 2009, 10:02:36 PM by Tiribulus »

Offline Vekseid

  • Full Member
  • ***
  • Posts: 548
  • Gender: Male
    • Elliquiy Adult Role Playing Forums
Re: My server configuration OK?
« Reply #48 on: February 19, 2009, 09:58:58 PM »
Be sure that your shared memory maximum can take the value -
Code: [Select]
cat /proc/sys/kernel/shmmax
268435456

That's mine, but the default is 32MB, not 256MB.
Adult Role Playing Forums - - Over five million posts - - Elliquiy's LAMP configuration (maybe NSFW)

Blog about Forums and Servers - - Twenty things to make Simple Machines Forum go faster

Private/Instant Message requests for free support will be ignored.

Offline Tiribulus

  • Sophist Member
  • *****
  • Posts: 1,016
  • Gender: Male
    • Tiribulus on Facebook
    • No Other God
Re: My server configuration OK?
« Reply #49 on: February 19, 2009, 10:57:49 PM »
Be sure that your shared memory maximum can take the value -
Code: [Select]
cat /proc/sys/kernel/shmmax
268435456

That's mine, but the default is 32MB, not 256MB.

4294967295

I assume that's bytes, but which default do you mean? The APC default probably. Mine read 30. I changed it to 64 for now

Offline Something like that

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 2,496
  • Gender: Male
  • ]
Re: My server configuration OK?
« Reply #50 on: February 19, 2009, 11:09:24 PM »
Be sure that your shared memory maximum can take the value -
Code: [Select]
cat /proc/sys/kernel/shmmax
268435456

That's mine, but the default is 32MB, not 256MB.

Odd. I have the default 32MB, but I'm running a 128MB shm in APC, and it's working fine.

Offline Tiribulus

  • Sophist Member
  • *****
  • Posts: 1,016
  • Gender: Male
    • Tiribulus on Facebook
    • No Other God
Re: My server configuration OK?
« Reply #51 on: February 19, 2009, 11:50:01 PM »
Where are you seeing what?

Offline Vekseid

  • Full Member
  • ***
  • Posts: 548
  • Gender: Male
    • Elliquiy Adult Role Playing Forums
Re: My server configuration OK?
« Reply #52 on: February 20, 2009, 02:14:06 AM »
Odd. I have the default 32MB, but I'm running a 128MB shm in APC, and it's working fine.

Linux is awesome and horrifying at the same time, it may let you allocate over 32mb, it'll only cause problems if you actually use it (and may just block it silently).

It's also per allocation, the normal mode is to use 32 mb and have apc allocate multiple blocks (I'd have to look up the settings >_>)
Adult Role Playing Forums - - Over five million posts - - Elliquiy's LAMP configuration (maybe NSFW)

Blog about Forums and Servers - - Twenty things to make Simple Machines Forum go faster

Private/Instant Message requests for free support will be ignored.

Offline Tiribulus

  • Sophist Member
  • *****
  • Posts: 1,016
  • Gender: Male
    • Tiribulus on Facebook
    • No Other God
Re: My server configuration OK?
« Reply #53 on: February 21, 2009, 04:53:34 PM »
Is it a problem that the client and global character sets are different? They also show as orange lines in phpmyadmin

character set client     utf8
(Global value)             latin1
character set connection utf8
(Global value)              latin1

Thanks