Trying to install Omeka2.6 and then Neatline on AWS server according to manual

Hi. I am trying to install Omeka and then Neatline on my Amazon Web Services server. I am using the following manual

https://drive.google.com/file/d/0Bz1FHvEQjbvKLWNfYnFCVEVkOEU/edit

which is from 2014 and references Omeka 2.0
sudo apt­get install unzip
sudo apt­get install php5
sudo apt­get install php5­mysql
sudo apt­get install apache2
sudo apt­get install mysql­server
sudo apt­get install imagemagick
sudo apt­get install php5­xsl

All went ok thus far. However,
it seems that the Omeka folder is empty even after unzipping, and the zip file still has the files based on size
drwxr-xr-x 8 ubuntu ubuntu 4096 Feb 15 00:41 omeka-2.6
-rw-rw-r-- 1 ubuntu ubuntu 16344458 Feb 15 14:44 omeka-2.6.zip

Hence
sudo mv omeka2.6/* /var/www/
sudo mv omeka2.6/.htaccess /var/www/
sudo rm /var/www/html/index.html

merely yields an internal server error when I put in my AWS IP which should yield Omeka starting up.

BTW I am using a 2008 iMac with 4GB RAM.

If anyone could help I’d much appreciate it! I set up user permissions and configured the MySQL database and Apache as per the above manual pp.22-26.

See Screencap

OmekaScreencap

Sincerely, Ariel Segal

1 Like

If you’re getting an Internal Server Error that’s coming from Apache, which should log the reason for the error in its error log, so check there. My initial guess would be that you don’t have the mod_rewrite module installed or activated, but it could be something else.

Where would the error log be? I’m running the Apache instantiation on a cloud server-Ubuntu through AWS…

Hi again. I don’t understand why, after I unzipped Omeka, and I got the results that it had unzipped successfully, and all the files were “inflated”, that only an empty Omeka directory was created having about 4K in it 4096 bytes. It said that Omeka was in an archive in Omeka-2.6.zip
drwxr-xr-x 8 ubuntu ubuntu 4096 Feb 15 00:41 omeka-2.6
-rw-rw-r-- 1 ubuntu ubuntu 16344458 Feb 15 14:44 omeka-2.6.zip
The zip file still has several megabytes worth of data in it.
FWIW when I did sudo mv omeka2.6/* /var/www/html/ it did not work because there was nothing in omeka 2.6 to move.
When I moved the empty folder to /var/www/html/ and removed the index.html placeholder the empty folder did indeed come up in my directory instead of a system error :grinning:
I suspect that if Omeka 2.6 is properly in the right directory and all the other permissions are tweaked as per the manual things will start to work.
If anyone could offer suggestions as to how to get the right software in the directory, I’d much appreciate it!
Best Ariel Segal

1 Like

All the files were unzipped, they’re just inside the “omeka-2.6” directory. The size reported for a directory in ls doesn’t include the sizes of the files inside it.

As for the location of your log, it would depend on your server, but /var/log is usually a good place to start looking for a directory with a name referencing apache.

I also didn’t notice before, you moved the contents of the omeka-2.6 folder to /var/www, not /var/www/html (at least if you used the commands you posted in your initial post). That could explain why you’re not seeing them.

Thanks! I had realized the change in structure and moved the Omeka folder to /var/www/html/ which is why it showed up OK when I put in my IP address into a browser. However, when I opened that folder in a browser, I found it contained nothing (though perhaps the files are hidden in the browser).

A further indication that it might be empty is the fact that the commands

sudo mv omeka2.6/* /var/www/html/
sudo mv omeka2.6/.htaccess /var/www/html/ failed, indicating that the “omeka 2.6” folder is empty [no contents, as would be signified by * directing the move of all contents to the new destination I believe?] Sorry-not really a coder per se.

Well, if you ran the commands you say, you already moved everything that used to be in that folder to /var/www. Do you have anything in /var/www?

I will check tonight. Would you be available to receive messages on this thread after 8 PM EST?

Hi. I think that everything in Omeka 2.6 did move properly to /var/www/html/ and the files are there!
drwxr-xr-x 8 ubuntu ubuntu 4096 Feb 15 00:41 .
drwxrwxr-x 3 root webdev 4096 Mar 6 05:18 …
drwxr-xr-x 3 ubuntu ubuntu 4096 Feb 15 00:41 admin
drwxr-xr-x 13 ubuntu ubuntu 4096 Feb 15 00:41 application
-rw-r–r-- 1 ubuntu ubuntu 5590 Feb 15 00:41 bootstrap.php
-rw-r–r-- 1 ubuntu ubuntu 532 Feb 15 00:41 db.ini
drwxr-xr-x 7 ubuntu ubuntu 4096 Feb 15 00:41 files
-rw-r–r-- 1 ubuntu ubuntu 1702 Feb 15 00:41 .htaccess
-rw-r–r-- 1 ubuntu ubuntu 597 Feb 15 00:41 index.php
drwxr-xr-x 6 ubuntu ubuntu 4096 Feb 15 00:41 install
-rw-r–r-- 1 ubuntu ubuntu 35147 Feb 15 00:41 license.txt
drwxr-xr-x 5 ubuntu ubuntu 4096 Feb 15 00:41 plugins
-rw-r–r-- 1 ubuntu ubuntu 1225 Feb 15 00:41 README.md
-rw-r–r-- 1 ubuntu ubuntu 32 Feb 15 00:41 robots.txt
drwxr-xr-x 5 ubuntu ubuntu 4096 Feb 15 00:41 themes

The error log notes that

“[Wed Mar 07 05:23:14.031661 2018] [core:error] [pid 1520] [client 96.241.194.91:60390] AH00124: Request exceeded the limit of 10 internal redirects due to probable configuration error. Use ‘LimitInternalRecursion’ to increase the limit if necessary. Use ‘LogLevel debug’ to get a backtrace., referer: http://18.217.236.218/

OK–> It looks like omeka is in the right directory [/var/www/html/ is the correct directory for current versions of ubuntu?]
Then I added myself as the “root” user following these steps
we are just going to use the root user as our default:
sudo groupadd webdev
sudo usermod a
G
webdev root
cd /var
sudo chown R
root.webdev www
sudo chmod 775 www
cd /var/www
sudo find . type
d | xargs sudo chmod 775
sudo find . type
f | xargs sudo chmod 664
sudo find files type
d | xargs sudo chmod 777
sudo find files type
f | xargs sudo chmod 666

Then it says

First, we need to set up a mysql database with a password for our root user (I am using “PaSsWoRd” here
again). We do this with the following command:
mysql -u root -p
You will be prompted to enter the password. This will enter us into the MySQL program, which you can tell
because the command line prompt has changed to mysql>. We are going to enter a series of commands
(being sure to have appended a semicolon to the end of each line) to set up our database for omeka.
Remember, I am using “root” as the user and “PaSsWoRd” as the password in this demo.
create database omeka;
grant all privileges on omeka.* to ‘root’@‘localhost’ identified by
’PaSsWoRd’;
flush privileges;
quit;
When I did this I got
mysql> create database omeka;
Query OK, 1 row affected (0.00 sec)

mysql> grant all privileges on omeka.* to ‘root’@‘localhost’ identified by ‘[my password]’;
Query OK, 0 rows affected (0.00 sec)

mysql> flush privileges;
Query OK, 0 rows affected (0.00 sec)

mysql> quit;

Is this ok so far?

Then in db.ini
[database]
host = "localhost"
username = "root"
password = "[My password]"
dbname = "omeka"
prefix = "omeka_"
charset = “utf8”
;port = “”

Then I enabled sudo a2enmod rewrite.

The manual says to
"change some configuration files by entering the following commands:
sudo a2enmod rewrite
cd /etc/apache2
sudo nano apache2.conf"

I put

# Enable mod_rewrite
<IfModule mod_rewrite.c>
RewriteEngine On
</IfModule>

at the bottom of the .conf file but above

# vim: syntax=apache ts=4 sw=4 sts=4 sr noet

Finally it said
“we now need to change another mod_rewrite file:
sudo nano /etc/apache2/sitesavailable/default
On the 11th line, we need to change “AllowOverride None” to “AllowOverride All”:”
However, that line is part of apache2.conf and no longer part of a default file as noted in

HOWEVER, should

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

be changed to /var/www/html/ ?

and I reset the apache2 database

but I still get
sudo /etc/init.d/apache2 restart
[Wed Mar 07 06:25:06.497204 2018] [core:error] [pid 1746] [client 69.41.14.233:38392] AH00124: Request exceeded the limit of 10 internal redirects due to probable configuration error. Use ‘LimitInternalRecursion’ to increase the limit if necessary. Use ‘LogLevel debug’ to get a backtrace.

Thanks for your patience! If needed, I can find another method to complete the project, but I would really like to be able to get Omeka up and running :slight_smile:

The instruction to add the RewriteEngine On block at the bottom of apache2.conf doesn’t make much sense, and probably shouldn’t be done. At best it does nothing, and I would remove it.

Does the URL in the URL bar change at all when you try to visit the site? Or, do you get anything different if you add /install on the end of the URL?

Hi! It looks like I am getting somewhere!!

http://18.217.236.218/install/

actually does bring up an Omeka page :slight_smile:

which says that the mod_rewrite is not enabled.

Will try enabling mod_rewrite tonight

The ip alone still yields an Internal Server Error, but mod_rewrite might help

sudo a2enmod rewrite has been done but website still says

mod_rewrite is not enabled.
Where does it need to be enabled? The manual says
"Our database is now configured, so now it is time to move on to configuring Apache. We need to let Omeka
be able to modify the web addresses, so we have to enable an option called mod_rewrite. We enable the
rewriting and change some configuration files by entering the following commands:
sudo a2enmod rewrite
cd /etc/apache2
sudo nano apache2.conf
You will see that we have entered the nano editor again. We need to go down to the bottom of the file (you
can page quickly by pressing ctrlV)
and enter some information at the bottom:
# Enable mod_rewrite

RewriteEngine On

Save the file again and exit (ctrlO
and ctrlX).
we now need to change another mod_rewrite file:
sudo nano /etc/apache2/sitesavailable/default
On the 11th line, we need to change “AllowOverride None” to "AllowOverride All"
Save the file and exit (ctrlO and ctrlX).
Now all we have to do is restart Apache with following command:
sudo /etc/init.d/apache2 restart
Your Omeka site is now all configured and ready to run!"

HLooking at older issue http://omeka.org/forums-legacy/topic/mod_rewrite-and-another-possibly-related-error/
It seems that now the default site is not
/etc/apache2/sitesavailable/default
but
/etc/apache2/sites-available/000-default.conf

So tantalizing to be almost there [File permissions and mysql permissions should be ok… username would be “root”]