Slow MySQL in VMWare, but Apache works ok - mysql

I have OSX running VMWare with W7 Pro. This machine is configured to bridge the network adapter, so it's in the same network of OSX but with a different local IP. I installed Apache and MySQL, and I use virtual hosts; so far, so good. Any virtual hosts that I create that don't use MySQL (just static HTML or PHP sites) load really fast on OSX's browsers, but sites that need to use MySQL take a long time to load. I've investigated a lot (as far as my language understanding allows) and the only solution that worked partially is to use
skip-name-resolve
This accelerated the loading time from 10 seconds to 8 or 7, but it's still annoying for development, and more if other sites load immediately. I appreciate any help you could give me.

Related

MacOS MySQL Gone Away and local networking issues due to GateKeeper

On MacOS Mojave 10.14.5, local services relying on TCP connections have connections randomly aborted, resulting in errors like "Mysql has gone away" and Nginx connection resets.
Seems like the Mojave OS is monitoring and blocking TCP connections, even if the firewall is disabled.
I managed to get MySQL working in a docker image, however this is much slower than native MySQL service. Same applies to NGinx.
A lot of blog articles online cover this issue with MySQL, recommending to increase wait_timeout and max_packet_size, which does not work in this case as the issue is most likely not with MySQL itself (in fact, local Nginx seems also to be affected).
Just spent 2.7K on a brand new MacBookPro and feel like I can't work with it...
Any help?
Chatted with Apple Support, who recommended to do an SMC reset, which I have done twice and it did not help... They don't really offer support for the OS issues... Was about to return the MacBookPro and buy a Linux laptop...
... and then figured it out!!!
As part of installation instructions for a third-party VPN software, I have been asked to run the following command on my MacOS Mojave 10.14.5:
sudo spctl --master-disable
This was to allow ALL applications to be installed on the system, bypassing System > Privacy settings (adding a third option "Allow all"), basically working around the GateKeeper service to allow for the VPN app to install.
This was meant to be disabling GateKeeper, so it won't interfere with the application, however it looks like GateKeeper is still doing something shady, and actually causing the networking issues.
Anyway, it was enough to switch it back and restart the MacBook:
sudo spctl --master-enable
in Terminal and reboot.

Cant browse the phpmyadmin and urls?

NOTE: I am using XAMPP
When I browse localhost/phpmyadmin or localhost/ even the localhost/xampp is not working it just says took too long to respond. I have tried changing the Listen 80 to 8080 in apache(httpd.conf) it didnt solve my problem.
It was working before and then somehow it not working.
Any help would be appreciated. Thank you
It is not port issue as apache is working just it is taking too much time in responding.
If xampp restarts your computer it might be taking too much resources from your PC. Monitor memory usage and disk usage from task manager.
On windows (specially windows10 ) disk usage makes problem with many application during windows update. If updates are downloaded and not installed; install and rebbot your machine.
If possiible you can try reinstalling XAMPP by taking backup of old configuration files.

Chrome Slow on Local IIS Sites

I've seen this problem reported by other people whereby Chrome is incredibly slow to respond on local sites hosted in IIS. This is whether I'm using localhost or a specific host file entry (like mysite.local).
Existing fixes suggest removing the IPV6 entries from the host file, but that doesn't sort it out on my machine.
I'm running windows 8.1, vs2013 and IIS 8.5.
Can anyone help - its driving me crazy!
open 'worker processes' in features view of IIS panel and see if an earlier request is holding up rest of the queue. This can occur if the previous process waits for I/O to complete for instance.

Server for mobile feed app (like Instagram, Twitter...)?

I've made a mobile native app with a feed system like Instagram/Twitter. In development mode I was just running a PHP/MySQL Apache local server, but now I need to publish the app and work with a real server. Which kind of server do I need? I just need to send http requests (JSON), loads of them!
Do I just need a hosting server like 1and1? (http://www.1and1.com/linux-web-hosting?__lf=Static)
But this one, it only has 1GB MySQL databases... not enough
Is there any kind of app/server whatever? Which kind of server does Instagram use?
These days lots of users are moving to the cloud.
Check out Amazon EC2: http://aws.amazon.com/ec2/
You can setup a micro instance server and it is very cheap to run tests on and get off the ground. Then if you like how it's running, you can simply upgrade to a more powerful server without having to re-install everything.
It also allows you to scale if your application gets really popular by just cloning the server.
Really worth checking out.

Wordpress Site SLOW to Load

I just uploaded a Wordpress site from my local machine to a Bluehost shared server. Ran fine locally, but now it is loading very slowly (107 seconds for home page). Bluehost tech support ran GTMetrix site analyzer and came back with "it's the CSS in your theme". They say nothing is wrong with the server.
I definitely need to clean up my CSS, but I didn't think it could have such a large impact on load times. Am I wrong?
Looking at the resource load times with Chrome's developer tools makes it immediately clear that it's your main document that is responsible for the delay; not the CSS, not anything else.
Therefore we have to assume it's something in your own code that causes the delay. Since it worked fine when run locally, the most likely scenario is that your code is trying to connect to some server (perhaps a database?) that it cannot connect to, and the delay is due to the connection finally timing out.
Recommendation: double check the places where you make connections to any external resource, and especially the credentials used when you do so. Is your host authorized to make these connections the same as your local development machine is? If you are connecting by IP, are those IPs accessible from your host?
The problem is loading
http://ad.doubleclick.net/adi/N5192.395082.LOT18.COM/B5529584;sz=300x250;ord=[timestamp]?
which is probably a script?
That takes 59 seconds for me. The rest is fast.
From the Chrome dev tools (Network tab): http://screencast.com/t/8DdtXeEv
The solution: turn off your ads.
You can use quick cache plugin which will speed up you site without compromise.
http://wordpress.org/extend/plugins/quick-cache/