I also found some instances of hda.localdomain that I had to make klovia.htt-consult.com
The 'best' thing IMNSHO is for you to present the FQDN that you think it is. Let them enter what they want to override it with then you have the FQDN and can split it to get host and domain then replace all three appropriately.
email server
Re: email server
More discoveries. I will try and batch them this time:
In patch/imapd.cnf
Why:
[ req_dn ]
C=US
ST=NY
L=New York
O=Courier Mail Server
OU=Automatically-generated IMAP SSL key
CN=localhost.localdomain
I don't live in NY and does the Organization need to be "Courier Mail Server"?
And why here CN does end with a period while it does in install-virtual-mail-1.2.sh:
openssl req -new -outform PEM -out smtpd.cert -newkey rsa:2048 -nodes -keyout smtpd.key -keyform PEM -days 365 -x509 -subj '/CN=localhost.localdomain.'
==========================
Same questions in pop3.cnf
============================
In amavisd.conf you have:
$mydomain = 'localhost';
#$mydomain = 'example.com'; # a convenient default for other settings
So should this be just the host (klovia) or the FQDN?
What about config.php and config.php-sql
Also in aliases:
root: postmaster@hda.com
That needs changing too?
In patch/imapd.cnf
Why:
[ req_dn ]
C=US
ST=NY
L=New York
O=Courier Mail Server
OU=Automatically-generated IMAP SSL key
CN=localhost.localdomain
I don't live in NY and does the Organization need to be "Courier Mail Server"?
And why here CN does end with a period while it does in install-virtual-mail-1.2.sh:
openssl req -new -outform PEM -out smtpd.cert -newkey rsa:2048 -nodes -keyout smtpd.key -keyform PEM -days 365 -x509 -subj '/CN=localhost.localdomain.'
==========================
Same questions in pop3.cnf
============================
In amavisd.conf you have:
$mydomain = 'localhost';
#$mydomain = 'example.com'; # a convenient default for other settings
So should this be just the host (klovia) or the FQDN?
What about config.php and config.php-sql
Also in aliases:
root: postmaster@hda.com
That needs changing too?
Re: email server
Ok, I managed to make the host update script a little more user friendly. I added the option to say if the hostname is correct or not. If not, you can manually enter the correct hostname.
I also made a few minor fixes as well. For your questions, I commented out the use of aliases, so it doesn't matter what it is set to at the moment. I was told it is not a good idea to mess with the alias file.
The certs can be changed if you desire, I didn't worry about it as it's trivial in my opinion at this point. I could remove the auto cert creation option to allow the user to input their own info. I was just trying to automate it more for those who want a simple mail install.
As for how things are updated, the host update script updates the install script and some of the patch files with the correct hostname. I do want to make this better, so if you have any ideas please let me know. I have uploaded the latest release at http://dl.getdropbox.com/u/1380867/virt ... 1.2.tar.gz.
Thanks for the feedback and with help from users like you, we can get this perfected and hopefully one day on Amahi.
I also made a few minor fixes as well. For your questions, I commented out the use of aliases, so it doesn't matter what it is set to at the moment. I was told it is not a good idea to mess with the alias file.
The certs can be changed if you desire, I didn't worry about it as it's trivial in my opinion at this point. I could remove the auto cert creation option to allow the user to input their own info. I was just trying to automate it more for those who want a simple mail install.
As for how things are updated, the host update script updates the install script and some of the patch files with the correct hostname. I do want to make this better, so if you have any ideas please let me know. I have uploaded the latest release at http://dl.getdropbox.com/u/1380867/virt ... 1.2.tar.gz.
Thanks for the feedback and with help from users like you, we can get this perfected and hopefully one day on Amahi.
ßîgƒσστ65
Applications Manager
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2
Applications Manager
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2
Re: email server
There seems to be a bug:
webmail]# ./host-update-virtual-mail-1.2.sh
'/host-update-virtual-mail-1.2.sh: line 6: syntax error near unexpected token `{
'/host-update-virtual-mail-1.2.sh: line 6: `function hostname {
webmail]# ./host-update-virtual-mail-1.2.sh
'/host-update-virtual-mail-1.2.sh: line 6: syntax error near unexpected token `{
'/host-update-virtual-mail-1.2.sh: line 6: `function hostname {
Re: email server
I tested it befpre I posted. Not sure what went wrong, but I will take another look. Sorry it didn't work. I will try to post the updated version tonight.
ßîgƒσστ65
Applications Manager
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2
Applications Manager
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2
Re: email server
Probably has to do with what my system returns for 'hostname -f' which is:
localhost.localdomain
And it looks like you are trying to parse this into three components: hst, grp, and dom, so it fails on my system.
Remember, too, that sometimes a server is put into a sub-zone, so even grp could be dotted...
Ah, I just checked my Centos 5 systems, and there in the /etc/hosts file, the FQDN comes BEFORE localhost.localdomain!
oqo3 ~]# cat /etc/hosts
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1 oqo3.htt-consult.com OQO3 localhost.localdomain localhost
::1 localhost6.localdomain6 localhost6
This is an important behavioral change for hostname. I am going to ask about this on the fedora-test list.
localhost.localdomain
And it looks like you are trying to parse this into three components: hst, grp, and dom, so it fails on my system.
Remember, too, that sometimes a server is put into a sub-zone, so even grp could be dotted...
Ah, I just checked my Centos 5 systems, and there in the /etc/hosts file, the FQDN comes BEFORE localhost.localdomain!
oqo3 ~]# cat /etc/hosts
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1 oqo3.htt-consult.com OQO3 localhost.localdomain localhost
::1 localhost6.localdomain6 localhost6
This is an important behavioral change for hostname. I am going to ask about this on the fedora-test list.
Re: email server
Blush.
hostname by itself reponds with:
klovia.htt-consult.com
I changed the script accordingly, but still get the error...
More testing.
Uhm, what shell or environment are you running?
Because I created a REAL simple script from yours:
cat test1
function correct {
echo
echo 'Is this correct (1=Yes,0=No): '
read answer
}
correct
And:
./test1
'/test1: line 1: syntax error near unexpected token `{
'/test1: line 1: `function correct {
And this works on my Centos notebook. So I wonder if the base AMAHI install does not install a needed tool?
hostname by itself reponds with:
klovia.htt-consult.com
I changed the script accordingly, but still get the error...
More testing.
Uhm, what shell or environment are you running?
Because I created a REAL simple script from yours:
cat test1
function correct {
echo
echo 'Is this correct (1=Yes,0=No): '
read answer
}
correct
And:
./test1
'/test1: line 1: syntax error near unexpected token `{
'/test1: line 1: `function correct {
And this works on my Centos notebook. So I wonder if the base AMAHI install does not install a needed tool?
Re: email server
There is a <ctl-M> at the end of each line in your host-update-virtual-mail-1.2.sh file and I suspect at the end of each line in your other scripts.
What system are you building these on? DOS? MAC?
And what environment are you running your test system under that allows this sort of line ending in scripts?
I fixed the script by opening it in vi and doing:
:set ff=unix
then saving it.
I made two modifications to host-update-virtual-mail-1.2.sh:
I added:
#!/bin/bash
at the beginning and took out the -f from the hostname command.
What system are you building these on? DOS? MAC?
And what environment are you running your test system under that allows this sort of line ending in scripts?
I fixed the script by opening it in vi and doing:
:set ff=unix
then saving it.
I made two modifications to host-update-virtual-mail-1.2.sh:
I added:
#!/bin/bash
at the beginning and took out the -f from the hostname command.
Re: email server
Hello,
Yea, I just noticed the ^M. I usually check for those, but forgot. I did make a change to the script and added an option to manually enter the hostname. It has been uploaded to the previous download site.
I use Windows when I build scripts, but convert the file to unix format. I was using gedit in linux to make changes, but it does not show the ^M. Only VI showed them
So, it should work fine now for anyone who wants to test it. This was designed on 32-bit, so it may not work on 64-bit.
Yea, I just noticed the ^M. I usually check for those, but forgot. I did make a change to the script and added an option to manually enter the hostname. It has been uploaded to the previous download site.
I use Windows when I build scripts, but convert the file to unix format. I was using gedit in linux to make changes, but it does not show the ^M. Only VI showed them

So, it should work fine now for anyone who wants to test it. This was designed on 32-bit, so it may not work on 64-bit.
ßîgƒσστ65
Applications Manager
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2
Applications Manager
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2
Re: email server
It is NOT available at:Hello,
Yea, I just noticed the ^M. I usually check for those, but forgot. I did make a change to the script and added an option to manually enter the hostname. It has been uploaded to the previous download site.
http://dl.getdropbox.com/u/1380867/virt ... 1.2.tar.gz
Which is where I last got it from....

Who is online
Users browsing this forum: No registered users and 19 guests