Who can help me start first use of Drupal on our eMac (1.25GHz-256Mb) running OSX 10.3.9?
Lately I have been all "pre installation questions", without success I have tried to get Drupal working, who can direct me in right direction?
(When I read in "Handbooks"tab, I see much technical stuff)
Kind regards, a mac-user.

Comments

frjo’s picture

On the handbook page "Mac OS X-specific guidelines" http://drupal.org/node/5338 you find the link to "installing Drupal on Mac OS X 10.3." http://maczealots.com/tutorials/drupal/.

And yes it's technical, hard to avoid when you want to set up a web server.

Roel Guldemond’s picture

thx for reaction...
unluckily "Drupal on Mac OS X 10.3." http://maczealots.com/tutorials/drupal/." leads to text about OSX 10.4!
is it possible to use OSX 10.3?

dtabach’s picture

Although the doc is for Tiger, I managed to create a webserver in my powerbook with MacOS 10.3 following the instructions in the link provided above.
The interface of Terminal.app is a bit different, but the procedure is the same.

You might want to have a look also at http://maczealots.com/tutorials/movabletype/panther/ as an additional reference.
It's about installing Movabletype on Panther. There are similar steps, such as installing MySQL.

Last but not least, download the freeware YourSQL - http://yoursql.ludit.it/ -, to create/manipulate databases in your local server. It has the same purpose of another popular app CocoaMYSQL. But YourSQL is more stable and functional.

Durval Tabach

Durval Tabach

pwolanin’s picture

That's a good tutorial on maczealots, and the process is essentially the same for 10.3 and 10.4- below are some more of my comments on this:

I assume you downloaded and have running mysql 4.1 or 5.0? Double check that you have a reasonble version of php (from terminal run "php -v"). Note, there may be password issues, since the installed version of apache/php under 10.3.9 uses the mysql 3 client library. Search the forums here for or on mysql.com for the solution.

I've set Drupal up on both Mac 10.3.9 and 10.4. The tricky part (as mentioned above) is that of setting up the web server properly. You have to enable personal web sharing, and the go in as super-user and edit /etc/httpd/httpd.conf so that .htaccess files will work, and so that you can (if you wish) set the document root to somewhere more accessible (I've made it /Users/Shared/www). You'll also have to enable mod_php by uncommenting the appropiate lines in httpd.conf. See below, for a diff of the original and the file I have working under 10.3.9.

Also, note, if you try to run Drupal out of your own /Sites folder, you'll have the problem again of .htaccess not being used. In this case, edit you own .conf file in /etc/httpd/users

Note 1- to edit as su: log in as a user with admin access, open terminal, cd to the right folder. Then execute "sudo nano httpd.conf". Enter your password, and you can edit away. note- pico is an alias to nano

You'll may also want to set up a cron job to execuate Drupal's cron.php. Use the command: "crontab -e". Note that you may need to used vim instead of the more friendly nano when you first create the file (use "export EDITOR=vim" or "export EDITOR=nano" to set the environment variable). From info about setting up a cron file run "man crontab" and "man 5 contab" from the terminal. The latter is especially useful, since it has examples.

Note 2- diff showing changes to /etc/httpd.conf
---------

<code>
new-host:/etc/httpd pwolanin$ diff -u httpd.conf.pwolanin-saved httpd.conf
--- httpd.conf.pwolanin-saved   Sun Oct 22 14:00:33 2006
+++ httpd.conf  Sun Oct 22 14:27:30 2006
@@ -236,7 +236,7 @@
 #LoadModule dav_module         libexec/httpd/libdav.so
 #LoadModule ssl_module         libexec/httpd/libssl.so
 #LoadModule perl_module        libexec/httpd/libperl.so
-#LoadModule php4_module        libexec/httpd/libphp4.so
+LoadModule php4_module        libexec/httpd/libphp4.so
 LoadModule hfs_apple_module   libexec/httpd/mod_hfs_apple.so
 LoadModule rendezvous_apple_module libexec/httpd/mod_rendezvous_apple.so
 
@@ -279,7 +279,7 @@
 #AddModule mod_dav.c
 #AddModule mod_ssl.c
 #AddModule mod_perl.c
-#AddModule mod_php4.c
+AddModule mod_php4.c
 AddModule mod_hfs_apple.c
 AddModule mod_rendezvous_apple.c
 
@@ -360,7 +360,8 @@
 # documents. By default, all requests are taken from this directory, but
 # symbolic links and aliases may be used to point to other locations.
 #
-DocumentRoot "/Library/WebServer/Documents"
+#DocumentRoot "/Library/WebServer/Documents"
+DocumentRoot "/Users/Shared/www"
 
 #
 # Each directory to which Apache has access, can be configured with respect
@@ -385,7 +386,7 @@
 #
 # This should be changed to whatever you set DocumentRoot to.
 #
-<Directory "/Library/WebServer/Documents">
+<Directory "/Users/Shared/www">
 
 #
 # This may also be "None", "All", or any combination of "Indexes",
@@ -401,7 +402,7 @@
 # override. Can also be "All", or any combination of "Options", "FileInfo", 
 # "AuthConfig", and "Limit"
 #
-    AllowOverride None
+    AllowOverride All
 
 #
 # Controls who can get stuff from this server.

---
Work: BioRAFT

pwolanin’s picture

from an e-mail from Roel

When we enter (in the program Terminal, 1.4.6 (v100.1.8):
“eMac:~ roel$ sudo apachectl graceful”
Terminal responds with:
”/usr/sbin/apachectl graceful: httpd not running, trying to start
Syntax error on line 244 of /etc/httpd/httpd.conf:
Invalid command '(static', perhaps mis-spelled or defined by a module
not included in the server configuration
/usr/sbin/apachectl graceful: httpd could not be started“

To be short:
We understand that our httpd.conf-file is wrong.
We can not check where what is wrong.
Since we are not able to find where this httpd.conf-file is located.
(A search in the finder for httpd.conf-file, does not return a search
result)

We do not know what to do now.
(We think we need a new httpd.conf-file. But we do not have a back-up from
our original httpd.conf-file. We had to save the httpd.conf-file after
removing the pound symbol ("#") from the beginning LoadModule and AddModule
listings.)

The httpd.conf file is located as listed: /etc/httpd/httpd.conf

You can probably only see this file by opening up a teminal window, and you probably have to use "sudo" to edit the file. For example, (when logged in as a user with administrator rights and in the terminal window):

$ cd /etc/httpd
$ sudo nano httpd.conf

Also, I assume you have personal web sharing turned on (under System Settings), etc?

I'm also a little confused by your comment, since how could you have edited this file if you can't find it?

---
Work: BioRAFT

Roel Guldemond’s picture

Thank you Peter (pwolanin)!

Since we are trying to get Drupal working on our eMac with OSX 10.3.9 in October, but did not have possibilities to make time free, we wil now be using this days off to try to get it working. Your quick and detailes answer encourages us.

We have changed:
Documentroot "/Library/Webserver/Documents"
into:
Documentroot "/Users/Shared/www".
Since there was no folder "www" in our "Users/Shared", we have been making such a "www"-folder by hand on this place
Question: Is this right to do it by hand?

Stan and I are carefully going step-by-step.

Today we went through the paragraph "Enabling and Testing PHP".
We have good hope since after:
eMac:~ roel$ sudo apachectl graceful
Terminal gives us back:
/usr/sbin/apachectl graceful: httpd gracefully restarted

Tomorrow we will be concentrating on the last paragraph of MacZealot's article: "Configuring Drupal"!
Best Regards from the Netherlands, Roel & Stan

P.S.
In answer to your 2 questions of Peter (plowanin):
1st)
"I assume you have personal web sharing turned on etc?":
Yes since we go through the article from top to bottom. (That will say that is father Roel's preference, his son Stan is more eager to try to make bigger steps!)
2nd)
"I'm also a little confused by your comment, since how could you have edited this file if you can't find it?"
I do now see how it works. However I cannot see httpd.conf-file after a search, with Terminal I can edit it after the command "sudo pico /etc/httpd/httpd.conf".
I would have liked to edit the httpd.conf-file in e.g. SubEthaEdit, so I can work quicker. But with the Terminal-option I also got where I wanted to be: a working httpd.conf-file! Thanks again!

*** I like contributing to improvement of systems. Hic sic: Boulding describes a system as: "that which is not chaos" ***

Roel Guldemond’s picture

$db_url = "mysql://root:mysql_password@localhost/drupal";

...where mysql_password is the root password you chose for the MySQL databae, and drupal is the MySQL database table you created for Drupal. Next, go down to line 90 of the config file. You'll want to edit the default path to match where your Drupal installation is located - most likely http://localhost/drupal. It should look similar to this example:

$base_url = 'http://localhost/drupal';

Save the file, and you're ready to use Drupal online! Open a browser, and enter the following address: http://localhost/drupal/. The basic Drupal front page should come right up.

So the a/m original line in settings.php:
$db_url = "mysql://root:mysql_password@localhost/drupal";,
we changed in:

$db_url = 'mysql://username:123@localhost/database.4.0.mysql';
$db_prefix = '';

And we added:
$base_url = 'http://localhost/drupal';

After pasting http://localhost/drupal/ in our browser, the article reads "The basic Drupal front page should come right up."
But..... we get following:
"Not Found
The requested URL /drupal/ was not found on this server.
Apache/1.3.33 Server at emac.local Port 80"

*** I like contributing to improvement of systems. Hic sic: Boulding describes a system as: "that which is not chaos" ***

pwolanin’s picture

Do you have drupal installed in the directory /users/Shared/www/drupal or in Users/Shared/www?

If the later (a simpler option), then you don't need the /drupal part for the http URL. The instructions are a little confusing, since it also seems the database name is "drupal".

I usually have it working without setting the base URL (better to not set if if you can). If you need to set it, i'd do something like http://127.0.0.1/drupal. However, for me http://localhost/drupal also works for me as a URL as I have Drupal 5.x installed in /User/Shared/www/drupal and Drupal 4.7.x installed in /Users/Shared/www/drupal-4-7.

---
Work: BioRAFT

Roel Guldemond’s picture

Since my experience is somewhere on the level of opening the box of a Mac I bought, and start using it for my work, do not blame me for checking following points with you:

  1. MacZealot's article reads in paragraph "Configuring Drupal": "...and drupal is the MySQL database table you created for Drupal.". I have filled in database.4.0.mysql, since in folder Library/WebServer/Documents/drupal-4.7.4/database (there is also a database.4.1.mysql in this folder) Question 1. Did I do this right?
  2. In point 1. you can see that I have most probably not placed the drupal files in the right directions. I feel I have mixed up in using the folders a) Library/WebServer/Documents/drupal-4.7.4/database and b) Users/Shared/www! I will look at this thoroughly next year!! Last Question (this year...): can I drag the drupal-files just from folder a) to b)?

For now: enjoy tonight's New Years Eve!
-My wife has picked up the tasks which I traditionally are taking care of on New Years Eve, since she supports us to get Drupal working! To be expected early 2007! (Sooner than Leopard??)-

*** I like contributing to improvement of systems. Hic sic: Boulding describes a system as: "that which is not chaos" ***

Roel Guldemond’s picture

I went through Matt Willmore's article "Installing Drupal on Tiger" at MacZealots.com, and the reaction's bij pwohalin and others again and again.
Little by little everything becomes more clear to me.
But I do not have drupal running yet on our eMac.
In the following paragraph over Willmore's article, I see that I have not yet a good understanding:
Willmore writes in the paragraph "Configuring SQL":

"Unfortunately, Drupal isn't as cool as WordPress in the fact that it won't automatically populate your database. Although there are great MySQL GUI's available for OS X like CocoaMySQL, we'll live on the edge today and do it all in UNIX. To accomplish this, we'll create the database, and populate it with a MySQL dump included with Drupal:

/usr/local/mysql/bin/mysqladmin -u root -p create drupal
/usr/local/mysql/bin/mysql -u root -p drupal < /Library/WebServer/Documents/drupal/database/database.mysql"

Reading this, I have done following attempts
these two sets of lines are puzzeling me:

1) Since I followed the tip of pwohalin to place drupal-files in /User/Shared/www, I typed:

eMac:~ roel$ /usr/local/mysql/bin/mysql -u root -p drupal < /Users/Shared/www/database/database.4.0.mysql
Enter password: 

After entering my password, nothing happens

2) Typing in a second time in terminal, terminal gives:

eMac:~ roel$ /usr/local/mysql/bin/mysql -u root -p drupal < /Users/Shared/www/database/database.4.0.mysql
Enter password: 
ERROR 1050 at line 6: Table 'access' already exists
eMac:~ roel$ 

Anyway I hoped would get the Drupal front page, after the last step in the article, viz.:

"Open a browser, and enter the following address: Open a browser, and enter the following address: http://localhost/drupal/drupal/"

Unluckily after "http://localhost/" or "http://127.0.0.1/" following is returned in my browser:
"Unable to connect to database server
This either means that the username and password information in your settings.php file is incorrect or we can't contact the MySQL database server. This could mean your hosting provider's database server is down.
The MySQL error was: Access denied for user: 'username@localhost' (Using password: YES).
Currently, the username is username and the database server is localhost.
a)* Are you sure you have the correct username and password?
b)* Are you sure that you have typed the correct hostname?
c)* Are you sure that the database server is running?
For more help, see the Installation and upgrading handbook. If you are unsure what these terms mean you should probably contact your hosting provider."

For the three questions, my answers are
a) Yes
b) localhost is the correct hostname, in my opinion
c) I would say yes (but the message "ERROR 1050 at line 6: Table 'access' already exists" makes me unsure

Therefore my a/m question: Who can help me?

*** I like contributing to improvement of systems. Hic sic: Boulding describes a system as: "that which is not chaos" ***

dtabach’s picture

I don't know what would be the unix correct commands. But I accomplished to create, give correct permissions and populate my drupal database using a MySQL GUI application. I'd rather YourSQL, better than CocoaMy SQL, but both of them will get things done very easily.

Durval Tabach

Durval Tabach

tknospdr’s picture

I would have liked to edit the httpd.conf-file in e.g. SubEthaEdit, so I can work quicker. But with the Terminal-option I also got where I wanted to be: a working httpd.conf-file! Thanks again!

You can edit it in whatever you like. Open your editor of choice and then command-O for open. Now hit command-shift-3 and navigate to wherever you want to go.

Thanks,
David
http://www.floridapets.org

pwolanin’s picture

not true- most editors that play nice with the Mac OS won't let you see /etc or other system folders.

I use JEdit, which seems to bypass this contol and seems like a pretty nice GPL, cross-platform programming editor: http://www.jedit.org/

---
Work: BioRAFT

tknospdr’s picture

You can even do it with Textedit, the lowliest of all the Mac OS X editors. And if you want to do it with admin privs you can just launch it via Terminal like so:

sudo open /Applications/TextEdit.app/

Thanks,
David
http://www.floridapets.org