Question

WordPress permalinks tried everything

I’m running Ubuntu Lamp and I can’t get WP permalinks working. I migrated my site using WordPress Duplicator which has worked for me many times before.

YES, .htaccess is writing properly. (there is also another .htaccess in /wordpress/.htaccess – but all indications show that WP writes to the one in the site root)

I have added Options Indexes FollowSymLinks MultiViews AllowOverride All Order allow,deny allow from all to the following files:

/etc/apache2/sites-available/default /etc/apache2/sites-available/mysite.com.conf

I have added ServerName localhost to:

/etc/apache2/httpd.conf

I have run:

<pre>a2enmod rewrite</pre>

Then restarted Apache.

I have created new mySQL databases and users and build new packages with Duplicator and tried those. I have tried disabling permalinks and then re-enabling after install.

For record, the site does work when permalinks are disabled.

I feel like I have tried just about every forum suggestion out there.

I’m just starting out so I’m fine scrapping the whole thing and starting over but I’m not convinced it would do anything. I feel like I’m still missing something.

Looking forward to your suggestions in the meantime I will keep digging.


Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

@jon: no … I didin’t come across that one (what does it do?)

But I solved my issue.

So I started fresh w/ Ubuntu 14.04 32bit …

<pre> <Directory /var/www/> Options Indexes FollowSymLinks AllowOverride None Require all granted </Directory> </pre>

to say <pre>AllowOverride All</pre>.

I think ^this is the part I was missing.

Then ran <pre>a2enmod rewrite</pre>.

Installed using Duplicator and set permalinks to Post Name.

Alls well that ends well, well that’s what I say.

First thing is you have to enable the URL rewrite module:

a2enmod rewrite

Second thing you have to edit the entry in your apache conf file.:

<VirtualHost *:80>
  here you have your regular stuff
</VirtualHost>

<Directory />
  Options FollowSymLinks
  AllowOverride None
</Directory>
<Directory /var/www/example.com/public_html>
  Options Indexes FollowSymLinks MultiViews
  AllowOverride All
  Order allow,deny
  allow from all
</Directory>

This comment has been deleted