Reputation: 131
I got tremendous performance issues with Vagrant and Magento. I hope you might be able to help me out on this.
Vagrantfile:
Vagrant.configure(2) do |config|
config.vm.box = "puphpet/debian75-x64"
config.vm.network "private_network", type: "dhcp"
# config.vm.network :forwarded_port, host: 8080, guest: 80
config.vm.synced_folder "./www", "/vagrant/www", type: "rsync", rsync__exclude: ".git/"
config.vm.provider "virtualbox" do |v|
v.memory = 2048
v.cpus = 4
end
config.vm.provider :virtualbox do |vb|
vb.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
vb.customize ["modifyvm", :id, "--natdnsproxy1", "on"]
end
# config.vm.synced_folder "./www", "/vagrant/www", group: "www-data", owner: "www-data"
end
OK, so far so good. I cloned my GIT Repo into the shared folder. I'm using a Wordpress Installation with magento integration (MWI Plugin). As long as I am not activating the Magento Plugin all fine, Pageload is about 2 sec as soon as I use the Plugin things going up to 60 seconds.
I have no idea what is going wrong here, as for the git origin (live server) everything is fine.
I read a few posts about the synced folder topic. I sticked with rsync for now, seems to be the fastest option. I tried NFS as well. No real difference here.
I'm happy for any hints on this. Thanks a lot, Steven
Upvotes: 1
Views: 1276
Reputation: 13971
You’re not alone. All Magento sites out of the box run slow. But your slow Magento site may be running even slower than the standard.
Some of the reasons may be :
No Full Page Cache (FPC). If you’re not running a copy of Magento Enterprise or are not on Magento Community 1.5+, chances are that you don’t have FPC activated. This one tool single handedly speeds up Magento sites by leaps and bounds.
Memory Limit Too Low. There is a setting in your configuration files which sets the maximum amount of memory you can dedicate to PHP processes. Since Magento is a big memory hog, having this value be greater than 128mB can significantly bump up the time it takes Magento to perform operations.
Indexes are not updated. If your indexes have not been updated manually through the admin panel, you’re causing your Magento site to figure out calculations every time a customer sees a page.
Not Using Memcached. Memcached is a memory object cacheing tool which in short means it can store user sessions and things that get queried in a cache.
Memcached can store and recall these things so much faster than your server can. Compilation Turned Off. This is a simple setting in the admin panel which compiles files into more easily accessible blocks of HTML. Lots of companies have this turned off because it breaks the site.
Developers Hacked The Core. “Hacking the core” means that your developers manually overwrote overwrote Magento files. Theoretically, this should never be the case, but it’s worth checking. Most tips on improving Magento speed overlook this key pitfall. Sometimes someone gets hired that gets the job quickly but doesn’t think too far ahead. Don’t let it slow you down – if you’re having speed issues, check if your core is hacked.
Bad Hosting. Cheap hosting companies who don’t advertise they have a custom Magento setup are generally bad at hosting Magento. Spend the extra money and find someone who supports what you’re trying to do.
Upvotes: 1