• Our team is looking to connect with folks who use email services provided by Plesk, or a premium service. If you'd like to be part of the discovery process and share your experiences, we invite you to complete this short screening survey. If your responses match the persona we are looking for, you'll receive a link to schedule a call at your convenience. We look forward to hearing from you!
  • We are looking for U.S.-based freelancer or agency working with SEO or WordPress for a quick 30-min interviews to gather feedback on XOVI, a successful German SEO tool we’re looking to launch in the U.S.
    If you qualify and participate, you’ll receive a $30 Amazon gift card as a thank-you. Please apply here. Thanks for helping shape a better SEO product for agencies!
  • The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.

Resolved JS files served with illegal characters

sjerp van wouden

New Pleskian
hi everyone

I've got an issue with JS files being served with illegal characters. [nak][stx] showing up. The files get corrupted.

Around the web a seemingly related issue has to do with vagrantbox's handling of sendfile.
in the nginx.conf one should add "sendfile = off". Also it's suggested to force UTF-8 encoding.
Reloading or restarting the nginx (and apache) does not resolve anything. Then again I don't have vagrantbox.

I've done all things suggested around the web and have been stuck the past 10 hours on this.

I have a relatively new Centos 7 VPS / 12.5 plesk installation with an Virtuozzo virtualisation. Only difference being that I've installed MariaDB 10.2 as my databases were mysql 5.6 which was incompatible with the 5.5.x shipped with plesk.

The frontend result can be seen at www.vloerwerk.org.

So this shows up in the middle of the jquery library:
ngth;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),R(f,d,e[d])));N.set(f,"hasDataAttrs",!0)}return e}return"object"==typeof a?this.each(function(){O.set(this,a)}):„-����„-��������������������•%������������@—%����x„-������������0„-�����@������0„-������������void 0!==c)return c;if(d=n.camelCase(a),c=O.get(f,d),void 0!==c)return c;if(c=R(f,d,void 0),void 0!==c)return c}else d=n.camelCase(a),this.each(function(){var c=O.get(this,d);O.set(this,d,b),

One would say this is not plesk but nginx related, however, serverfault refused this question.

This issue goes in tandam with 404 on css.map and js.map files.

Also I support that any non wp-admin, non frontpage url giving me a 404 is also related.

regards
Sjerp

--------------------------------------------------

HYPOTHESIS

Well it's still kind of puzzling, but this seems to be the case:
The apache-nginx (under plesk) cannot deal with corruption. Be it from a single record or a single file. The apache keeps going but the nginx get confused and writes garbage into the thing it specifically does, being sending the static files. So a corrupted featured image in Wordpress can mess up your JS. After you've confused nginx once, it's a lost fight for this WP. Reinstall completely (hard learned lesson). The "sendfile off" issue seems related due to it's context but is not at all related.

PRACTICALLY

Never have corrupted files. When trying to recover sites after for example corrupted file systems, take a working backup and put that online, put your corrupted WP in Xampp; export the posts through the XML exporter and transfer posts manually from the XML file. Don't transfer images that's dangerous: one corrupt file will kill your system. Open them in paint or something and save again so that corruption gets removed.
 
Last edited:
listing some tried things.

assuming: additional nginx directives in plesk makes /etc/nginx/nginx.conf obsolete; direct edit of plesk nginx conf not possible (autogenerated); work through 'plesk additional nginx directives' in apache & nginx settings. "sendfile off;" no effect. Cannot write contexts here also. Assumption is also wrong. Conf loaded in series.

It could be related to nginx serves corrupted files when files edited in host mounted volume · Issue #68 · noplay/docker-osx · GitHub
"I get weird file corruption when mounting /var/www into this container."
Indeed my stuff is in /var/www. The suggested solution (nest the sendfile off) does not seem to apply.
 
Last edited:
Then finally I resolved to reinstalling my entire VPS. Now files are server normally, initially!

I thought it was fixed but no. This might be the culprit: AFTER i entered wp-admin, looked into updating WP, I noticed my screen got jumbled. And then in the console the good old errors because of the corrupted js files started showing up again...

Here's the riddle...
update core -> reinstall WP fixes it; all styles and JS good again.
then switching to frontpage messes it up again.
where you're on the update core page, it's all messy again.
 
Last edited:
Back
Top