Reputation: 371
I am using vagrant, its very slow, i tried every solution suggested at the internet, it doesn't help. So I decided trying to track the problem, inside the server.
Server uses apache, mysql, memcached, php.
When I use top, I see that server is not loaded at all. Cpu is maximum 1.5% when I do query, but it still takes 20 minutes to load one page.
What i noticed that all the processes are running under priority 20 - nice 20. And apache process is appears once every 5 seconds.
I am wondering what doesn't allow it use up to 100% of cpu and memory. Memory usage is also low, its 238 MB out of 4GB for apache and 331 mb for MYSQL here how it looks:
3441 www 20 0 231m 41m 4848 S 1.3 1.1 0:14.68 apache2
So the page loads for 15 minutes at the moment..
I executed some commands to give you more details:
admin$ vmstat
procs -----------memory---------- ---swap-- -----io---- -system-- ----cpu----
r b swpd free buff cache si so bi bo in cs us sy id wa
0 0 0 3599460 5140 89516 0 0 21 1 161 352 0 1 99 0
admin$ iotop
Total DISK READ: 0.00 B/s | Total DISK WRITE: 0.00 B/s
TID PRIO USER DISK READ DISK WRITE SWAPIN IO> COMMAND
1 be/4 root 0.00 B/s 0.00 B/s 0.00 % 0.00 % init [2]
2 be/4 root 0.00 B/s 0.00 B/s 0.00 % 0.00 % [kthreadd]
3 be/4 root 0.00 B/s 0.00 B/s 0.00 % 0.00 % [ksoftirqd/0]
6 rt/4 root 0.00 B/s 0.00 B/s 0.00 % 0.00 % [migration/0]
7 rt/4 root 0.00 B/s 0.00 B/s 0.00 % 0.00 % [watchdog/0]
8 be/0 root 0.00 B/s 0.00 B/s 0.00 % 0.00 % [cpuset]
9 be/0 root 0.00 B/s 0.00 B/s 0.00 % 0.00 % [khelper]
10 be/4 root 0.00 B/s 0.00 B/s 0.00 % 0.00 % [kdevtmpfs]
11 be/0 root 0.00 B/s 0.00 B/s 0.00 % 0.00 % [netns]
The process is still running it only gives bigger then zero once in a while. like 1.5 kb
user# dstat
You did not select any stats, using -cdngy by default.
----total-cpu-usage---- -dsk/total- -net/total- ---paging-- ---system--
usr sys idl wai hiq siq| read writ| recv send| in out | int csw
0 1 99 0 0 0| 30k 18k| 0 0 | 0 0 | 161 351
0 1 98 0 0 1| 0 0 |2073B 1216B| 0 0 | 267 543
0 1 99 0 0 0| 0 0 |1640B 710B| 0 0 | 225 460
1 1 98 0 0 0| 0 0 |1793B 762B| 0 0 | 257 537
1 1 98 0 0 0| 0 0 |1209B 729B| 0 0 | 174 349
0 1 99 0 0 0| 0 0 |1463B 534B| 0 0 | 254 520
0 1 99 0 0 0| 0 24k|1718B 689B| 0 0 | 244 488
Seems like it doesn't user resources, why?
Upvotes: 3
Views: 1806