unmanaged VPS with Cpanel - 2GB RAM - Site loading very slow
-
I am running a site named GetIndianStuff_COULD BE HACKED ONLY VIEW VIA SANDBOX (GUV's EDIT HERE)_.com.
I bought a unmanaged VPS with Cpanel - 2GB RAM.
My site is loading very slow, and also if i submit a post, then it gets about 2 to 5 min to get process.
But i was using Shared hosting where everything was going fine.
What are the tweaking s that i need to set in the php.ini
Which caching is best for VPS and How do i need to install through WHM/Cpanel
Your help needed in this regard.
Posted 11 months ago # -
hey dhanasekar,
took a look via a sandbox *. you may have been hacked, possibly had a code injection, else have you added some page element recently? seems to me that the popup is the issue. Did you know your page auto-loads a second unrelated site as well? looks pretty dodgy, frankly, whether legitimate or not.
* could be too late for that. If I were you I'd likely virus-check my local machine as well.
goto http://tools.pingdom.com to find out what page element is causing grief. I'd bet on the popup. Try deleting it and have another go. Check your soiurce code too for anomalous code, and your htaccess file if you're running Apache (scroll right to the bottom of the file, there's sometimes lots of space to hide malicious redirections.)
Otherwise, this isn't the priority but for the record, in php.ini you can play with the directives in the "Resource Limits" section, particularly ..
memory_limit = 48M
.. try increasing to 64 or 96M.
You may need to optimise the db too.
Really though, site behavior suggests this is bad code so I'd start there.
Were that my site, I have to say, the first thing I'd do is to take it offline, replaced with a Maintenance page, to protect my site visitors, before calling it from a sub-directory while troubleshooting. There's a chance you're exposing your site visitors (and your reputation) to malicious activity.
Sorry. Let me know how you get on.
I've edited your post to change the URL to protect vpsBible folks, just to be safe. Don't take it personally ;)
Posted 11 months ago # -
Hai the_guv,
First of all thanks for your reply.
1. I have checked all the pages throughly. I did not find any iframe codes.
2. I have put some popup add code in my site for earnings where i pay with that earnings for my VPS.
3. I have checked the .htaccess file and its safe.
4. I have increased the memory_limit to 96MB as you said.
5. In my VPS panel i use only 16% RAM from 2GB RAM. How to utilize the RAM fully?
6. Now i have enabled the eaccelerator and the site loads a bit fast than before. The main problem i face at present is that while submitting a article from my admin page it takes around 1 minute to publish.
Where as in my old shared hosting it will not take more than 3 sec to publish.
Can you tell me some mysql optimizations to improve my VPS
Regards
DhanaPosted 11 months ago # -
well, dhanasekar, on the MySQL side the four parameters in the "Resource Limits" section are worth looking at as is optimizing the db.
but what tech are you using, apache, nginx, a mix or whatever else, what's the php config overview, and what if any cms?
Most importantly for now though, what do the site, server and mysql error logs say?
Posted 11 months ago # -
I am using Datalife Engine CMS Software for my site.
Tech is apache.
I dont have any error logs till now.
My my.cnf file simply looks like this
[mysqld]
set-variable = max_connections=500
log-slow-queries
safe-show-databaseBut i have searched in google and many are saying that my.cnf has many configurations like the following.
[mysqld]
back_log = 75
skip-innodb
max_connections = 500
key_buffer = 384M
myisam_sort_buffer_size = 64M
join_buffer_size = 1M
read_buffer_size = 1M
sort_buffer_size = 2M
table_cache = 1800
thread_cache_size = 384
wait_timeout = 7200
connect_timeout = 10
tmp_table_size = 64M
max_heap_table_size = 64M
max_allowed_packet = 64M
max_connect_errors = 1000
read_rnd_buffer_size = 524288
bulk_insert_buffer_size = 8M
query_cache_limit = 4M
query_cache_size =128M
query_cache_type = 1
query_prealloc_size = 65536
query_alloc_block_size = 131072
default-storage-engine = MyISAMI tried to add the Query Cache size in my my.cnf file
[mysqld]
set-variable = max_connections=500
query_cache_size = 52428800;
query_cache_type = 1
log-slow-queriesAfter restarting the mysql i am getting the following error.
Starting MySQL. ERROR! Manager of pid-file quit without updating file.Kindly help me to sort out this problem.
I want to optimize the my.cnf and http.conn file.Regards
Dhana
safe-show-databasePosted 11 months ago # -
Dhana, sorry, I should have asked already .. what does the command "top" come up with?
It still sounds to me like some errant process.
Posted 10 months ago # -
Hai Guv,
Sorry, I could not understand your question.
Can you plz explain a bit more elaborately.
Kind Regards
Posted 10 months ago # -
Hai Guv,
Just now i saw this in my WHM
Command - whostmgr2 - top ./top
Posted 10 months ago # -
just type "top" at the CLI, Dhana. Are there any processes at the top of the list, chewing your resources?
Posted 10 months ago # -
Hai Guv,
Here is the screenshot of the top command.
http://lulzimg.com/i23/61624c.jpg
Can you optimize my VPS.
My VPS need to be optimized.
Please do the needful
Posted 10 months ago # -
Top output looks fine but, reverting back, did you try http://tools.pingdom.com? When I looked at your site, that popup (or some concerning code) was killing the pageload. What output do you get from the "pingdom" tool?
Posted 10 months ago #
Reply
You must log in to post.
Want HTML?
a blockquote code em strong ul ol liPlace code between backticks `codeHere`
You've got it.
