Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Questions concerning SQL+MTA+httpd
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
bedazzled
n00b
n00b


Joined: 21 May 2005
Posts: 39

PostPosted: Tue Feb 21, 2006 7:01 pm    Post subject: Questions concerning SQL+MTA+httpd Reply with quote

I don't know if this is the right place to ask, but i'll give it a try.
I have a couple of spreadsheets (*.ods format) and I use them as a "basic" form of database, about ~50 emails, names, telephone numbers from friends etc. and I want to migrate to an SQL solution (which one though?), to do some things more "automagically":
1) Generate html pages from the SQL base and zip them regularly (cron).
2) Exclude some fields from the base to the html pages.
3) Send an automated email via sendmail(?) every christmas and easter to all my friends and something more advanced: send an email to someone, when it's his/hers name day.

Can someone recommend me a good tutorial/howto as I'm fairly new to this area?
Thanks in advance. :)
Back to top
View user's profile Send private message
WhimpyPeon
Apprentice
Apprentice


Joined: 18 Oct 2003
Posts: 158
Location: Columbus, Nebraska

PostPosted: Tue Feb 21, 2006 9:12 pm    Post subject: Reply with quote

What you are looking for is pretty specific and I doubt you will find one tutorial that covers your project. If I was going to do it with gentoo I would do as follows:

Install mysql as your database (plenty of information here in these forums).
Install apache and PHP for your web server (be sure to include the cli version of php).
You might want to look into pear mail and pear DB for later use.
Install phpmyadmin to manager your database server.

You can write php scripts that will create your html documents through cron. Php can also be used to create web pages on the fly. I like php because it is easy to learn and relatively powerful and secure if you use it right.

There are plenty of sites that have tutorials on how to write php code. There are also many good books out on using mysql and php for web page development.

Good Luck!
Back to top
View user's profile Send private message
bedazzled
n00b
n00b


Joined: 21 May 2005
Posts: 39

PostPosted: Tue Feb 21, 2006 11:48 pm    Post subject: Reply with quote

WhimpyPeon wrote:
If I was going to do it with gentoo I would do as follows:

Yes, I am using Gentoo. :)
WhimpyPeon wrote:
Install mysql as your database (plenty of information here in these forums).
Install apache and PHP for your web server.

Do you think that Apache+MySQL is a bit "overkill"? Currently, I am going to experiment on my desktop*, later on I will move these services on a small home server.
* amd64 3000+, 1GB RAM.
WhimpyPeon wrote:
(be sure to include the cli version of php)

Which one do you mean?
Code:
bedazzled@desktop ~ $ emerge -pv php

These are the packages that I would merge, in order:

Calculating dependencies

!!! The short ebuild name "php" is ambiguous.  Please specify
!!! one of the following fully-qualified ebuild names instead:

    dev-lang/php
    dev-php/php

Should I choose PHP 4 or 5? Apache 1 or 2?
WhimpyPeon wrote:
I like php because it is easy to learn and relatively powerful and secure if you use it right.

I am a bit concerned about security+php though... very notorious language.
WhimpyPeon wrote:
Good Luck!

Thanks for the hints. :)
Back to top
View user's profile Send private message
WhimpyPeon
Apprentice
Apprentice


Joined: 18 Oct 2003
Posts: 158
Location: Columbus, Nebraska

PostPosted: Wed Feb 22, 2006 4:38 am    Post subject: Reply with quote

Perhaps I didn't understand your original post. I thought in line 2 you wanted to generate web pages for publication.

Ignore my post.

As far as php goes dev-lang/php is the new method. You could still use php in your cron job without apache. Look at the upgrade guide and you should be able to get a little information about the different ways of compiling php.

I am now assuming you are using openoffice base as your database. I really don't use that program and don't even know if php can read from it. I am a great fan of mysql and it really doesn't have that much overhead on your system (probably less than a running copy of openoffice). However, for a desktop system I'm not sure it is such a great idea. I suppose you could have it built and only start it when you need to do something with the data. This could be done from your cron job.

If you are only dealing with ~50 names, you could easily get away with a simple comma seperated file. You could then do a little script magic (pick your language... php, sh, awk, sed...) on that text file. That would consume the least overhead of all the solutions.

Sorry for any misinformation.

P.S. Your "small" home server (amd64 3000+, 1GB RAM) would be MORE than enough to do a small web site on apache and mysql with an e-mail server running also. Kind of like hauling a bike overseas on a cruise ship :lol: .
Back to top
View user's profile Send private message
bedazzled
n00b
n00b


Joined: 21 May 2005
Posts: 39

PostPosted: Wed Feb 22, 2006 11:30 am    Post subject: Reply with quote

WhimpyPeon wrote:
I thought in line 2 you wanted to generate web pages for publication.

I want to generate html pages for backup and I need an httpd to do the editing (it could be done via CLI+pure SQL, but I guess it is much hassle..)

WhimpyPeon wrote:
I am now assuming you are using openoffice base as your database.

Actually I am using the OpenOffice Calc (Base needs the java-stuff, certainly not my taste)

WhimpyPeon wrote:
P.S. Your "small" home server (amd64 3000+, 1GB RAM) would be MORE than enough to do a small web site on apache and mysql with an e-mail server running also.

Heh, the (amd64 3000+, 1GB RAM) is my desktop, not the server (probably I will use an Athlon 900MHz+64MB ram later on).
Back to top
View user's profile Send private message
WhimpyPeon
Apprentice
Apprentice


Joined: 18 Oct 2003
Posts: 158
Location: Columbus, Nebraska

PostPosted: Thu Feb 23, 2006 12:31 am    Post subject: Reply with quote

Quote:
I want to generate html pages for backup and I need an httpd to do the editing.
You do not need httpd to edit pages.
Quote:
Actually I am using the OpenOffice Calc (Base needs the java-stuff, certainly not my taste)
Then EXACTLY what form of SQL database do you wish to use.
Quote:
(it could be done via CLI+pure SQL, but I guess it is much hassle..)
It is a little hard to use CLI+pure SQL on a spreadsheet.
Quote:
Heh, the (amd64 3000+, 1GB RAM) is my desktop, not the server (probably I will use an Athlon 900MHz+64MB ram later on).
Read your previous post and let me know how I was to think anything other than this was your intended server.

After our little "dance" I have absolutely no idea what you are trying to accomplish here.

Perhaps if you could think through and explain what you want I or somebody else around this forum could help you out. I can't read your mind and your posts are not apparently clear on what you want.
Back to top
View user's profile Send private message
bedazzled
n00b
n00b


Joined: 21 May 2005
Posts: 39

PostPosted: Thu Feb 23, 2006 4:24 pm    Post subject: Reply with quote

WhimpyPeon wrote:
Quote:
I want to generate html pages for backup and I need an httpd to do the editing.
You do not need httpd to edit pages.

I mean I want to edit them via an easy interface (I've already emerged phpmyadmin+apache) AND backup them regularly in a zip containing html pages (SQL ---convert---> HTML).

WhimpyPeon wrote:
Quote:
Actually I am using the OpenOffice Calc (Base needs the java-stuff, certainly not my taste)
Then EXACTLY what form of SQL database do you wish to use.
Quote:
(it could be done via CLI+pure SQL, but I guess it is much hassle..)
It is a little hard to use CLI+pure SQL on a spreadsheet.

I will copy/paste them FROM the spreadsheet into phpmyadmin interface. Then rm foo.ods.

WhimpyPeon wrote:
Quote:
Heh, the (amd64 3000+, 1GB RAM) is my desktop, not the server (probably I will use an Athlon 900MHz+64MB ram later on).
Read your previous post and let me know how I was to think anything other than this was your intended server.

bedazzled wrote:
Do you think that Apache+MySQL is a bit "overkill"? Currently, I am going to experiment on my desktop*, later on I will move these services on a small home server.
* amd64 3000+, 1GB RAM.

The asterisk clearly points to desktop, not server...

Thanks anyway. :)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum