Hi,
I have a friend who purchased a JumpBox recently. He has the latest 1.1 version JumpBox and I'm trying to help him migrate his database to this version (he previously had an rPath appliance made by some individual).
His entire blog has used Permalinks and I can't find a way to configure the JumpBox to allow Permalinks to be turned on. It appears that most, if not all, of the files that WordPress refers to are locked down (owned by "root").
This is the article:
http://codex.wordpress.org/Using_Permalinks
He uses "Pretty Permalinks", not "Almost Pretty Permalinks". This is an example:
http://wp.retrodc.com/wordpress/2008/06/20/drive-in-dan-brings-you-his-r...
Since his blog is quite popular, Google and other search engines already have these links recorded, so switching to a non-Permalink site would be very inconvenient, if not damaging to the site's popularity.
These are the instructions as per WordPress:
* Apache web server with the mod_rewrite module installed
* In WordPress's home directory,
o The FollowSymLinks option enabled
o FileInfo directives allowed (e.g. AllowOverride FileInfo, AllowOverride All)
o An .htaccess file (if this file is missing, WordPress will try to create it when you activate "pretty" permalinks)
o If you want WordPress to update the .htaccess file automatically, WordPress will need write access to the file.
I added an .htaccess file to the /storage/wordpress directory, and added appropriate options to this, but the file is owned by user/group admin/admin. I'm not sure what security context WordPress is running under, but it doesn't update this file, but I can't change the "group" of the file to www-data (Operation not permitted is returned).
Any ideas where I should be looking to make this work?
Thanks!
Eric
Modified response
I didn't realize the first time I posted my solution that the less-than and greater-than symbols were interpreted, so I fixed the post.
Permalinks in WordPress JumpBox
Hey, thanks for the feedback. I am glad it worked for you.
Austin
Permalinks in WordPress JumpBox
Just wanted to follow-up that creating a file called .htaccess in the /storage/wordpress directory with the following contents:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /wordpress/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /wordpress/index.php [L]
</IfModule>
worked just fine. I'm not sure what permissions WordPress needs to actually create this file (since it says it will do it automatically if it has permission), but manually creating it worked for me.
We've had numerous security issues in past versions of WordPress, so keeping the permissions as tight as possible is definitely suggested.
Thanks again Austin!
Eric
(I modified my response since I noticed that the code was being interpreted and filtered some of the contents that should go in the .htaccess file)
Hi Austin, Fantastic!
Hi Austin,
Fantastic! Thanks! I'll give this a try, and if I get Permalinks working, I'll post what I did, since I'm pretty sure it's a common practice to have WordPress blogs use Permalinks since search engines like them.
Thanks again! I'll be in touch.
Eric
Permalinks in WordPress JumpBox
Hi Eric,
The permissions on the files of many of our applications are carefully set to be as safe as possible while still allowing users to accomplish what they need. By default, many of the files will not be editable by the 'admin' user, HOWEVER, the admin user can switch to root or perform certain commands as the root user, so ultimately the admin user can do whatever he/she wants.
This FAQ entry explains a little bit:
http://www.jumpbox.com/archives/140_how-to-access-a-jumpbox-as-root.html
So the key here, is if you are the admin user and want to do something as root, you can just put sudo in front of the command. If you want to do lots of things as root you can do sudo -s and this will switch you to the root user until you press CTRL+D.
As far as specifically making PermaLinks work I am not sure since I have not tried it. Sometimes these things work out easily with the way the application is setup in a JumpBox and sometimes there are conflicts. Let us know how it goes for you now that you know how to use sudo.
Austin