LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-19-2011, 10:50 AM   #1
loveulinux
Member
 
Registered: Aug 2011
Posts: 68

Rep: Reputation: Disabled
squirrelmail problem


Hi..All,
I followed this link to install & configure squirrel mail on ubntu 11.04. I followed each step as it is in the url but at last if I type "localhost/webmail" in the browser, it is giving the error as below
Quote:
Forbidden

You don't have permission to access /webmail on this server.
Apache/2.2.17 (Ubuntu) Server at localhost Port 80
But I am able to browse wiki pages if give only localhost.
The transparent proxy is configured in the same machine and working fine. The details as below
eth0---192.168.1.2(internet)
eth1---192.168.0.1(lan)
Please see the iptables rules and let me know if any port has to opened.
Quote:
#iptables -L
Chain INPUT (policy DROP)
target prot opt source destination
ACCEPT all -- anywhere anywhere
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
ACCEPT all -- anywhere anywhere

Chain FORWARD (policy ACCEPT)
target prot opt source destination
ACCEPT all -- anywhere anywhere

Chain OUTPUT (policy ACCEPT)
target prot opt source destination
ACCEPT all -- anywhere anywhere
ACCEPT all -- anywhere anywhere

iptables -L -t nat
Chain PREROUTING (policy ACCEPT)
target prot opt source destination
DNAT tcp -- anywhere anywhere tcp dpt:www to:192.168.0.1:3128
REDIRECT tcp -- anywhere anywhere tcp dpt:www redir ports 3128

Chain INPUT (policy ACCEPT)
target prot opt source destination

Chain OUTPUT (policy ACCEPT)
target prot opt source destination

Chain POSTROUTING (policy ACCEPT)
target prot opt source destination
MASQUERADE all -- anywhere anywhere
Please help me to fix this squirrel mail problem.

Last edited by loveulinux; 11-19-2011 at 10:52 AM. Reason: correction
 
Old 11-20-2011, 03:39 AM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Hi,

In the very first lines of the guide you followed, it says to add index.php in the DirectoryIndex directive.
Have you done that?
 
1 members found this post helpful.
Old 11-20-2011, 11:26 AM   #3
loveulinux
Member
 
Registered: Aug 2011
Posts: 68

Original Poster
Rep: Reputation: Disabled
Hi..Thanks for the reply.
The index.php is already there in /etc/apache2/mods-enabled/dir.conf file. As you said I followed this link. Please see my PC configuration files.
Quote:
cat /etc/apache2/conf.d/security | sed '/ *#/d; /^ *$/d'
ServerTokens Prod
ServerSignature Off
TraceEnable Off
Quote:
cat /etc/apache2/mods-enabled/dir.conf | sed '/ *#/d; /^ *$/d'
<IfModule mod_dir.c>
DirectoryIndex index.html index.cgi index.pl index.php index.xhtml index.htm
</IfModule>
Quote:
cat /etc/apache2/mods-enabled/mime.conf | sed '/ *#/d; /^ *$/d'
<IfModule mod_mime.c>
TypesConfig /etc/mime.types
AddType application/x-compress .Z
AddType application/x-gzip .gz .tgz
AddType application/x-bzip2 .bz2
AddLanguage am .amh
AddLanguage ar .ara
AddLanguage be .be
AddLanguage bg .bg
AddLanguage bn .bn
AddLanguage br .br
AddLanguage bs .bs
AddLanguage ca .ca
AddLanguage cs .cz .cs
AddLanguage cy .cy
AddLanguage da .dk
AddLanguage de .de
AddLanguage dz .dz
AddLanguage el .el
AddLanguage en .en
AddLanguage eo .eo
RemoveType es
AddLanguage es .es
AddLanguage et .et
AddLanguage eu .eu
AddLanguage fa .fa
AddLanguage fi .fi
AddLanguage fr .fr
AddLanguage ga .ga
AddLanguage gl .glg
AddLanguage gu .gu
AddLanguage he .he
AddLanguage hi .hi
AddLanguage hr .hr
AddLanguage hu .hu
AddLanguage hy .hy
AddLanguage id .id
AddLanguage is .is
AddLanguage it .it
AddLanguage ja .ja
AddLanguage ka .ka
AddLanguage kk .kk
AddLanguage km .km
AddLanguage kn .kn
AddLanguage ko .ko
AddLanguage ku .ku
AddLanguage lo .lo
AddLanguage lt .lt
AddLanguage ltz .ltz
AddLanguage lv .lv
AddLanguage mg .mg
AddLanguage mk .mk
AddLanguage ml .ml
AddLanguage mr .mr
AddLanguage ms .msa
AddLanguage nb .nob
AddLanguage ne .ne
AddLanguage nl .nl
AddLanguage nn .nn
AddLanguage no .no
AddLanguage pa .pa
AddLanguage pl .po
AddLanguage pt-BR .pt-br
AddLanguage pt .pt
AddLanguage ro .ro
AddLanguage ru .ru
AddLanguage sa .sa
AddLanguage se .se
AddLanguage si .si
AddLanguage sk .sk
AddLanguage sl .sl
AddLanguage sq .sq
AddLanguage sr .sr
AddLanguage sv .sv
AddLanguage ta .ta
AddLanguage te .te
AddLanguage th .th
AddLanguage tl .tl
RemoveType tr
AddLanguage tr .tr
AddLanguage uk .uk
AddLanguage ur .ur
AddLanguage vi .vi
AddLanguage wo .wo
AddLanguage xh .xh
AddLanguage zh-CN .zh-cn
AddLanguage zh-TW .zh-tw
AddCharset us-ascii .ascii .us-ascii
AddCharset ISO-8859-1 .iso8859-1 .latin1
AddCharset ISO-8859-2 .iso8859-2 .latin2 .cen
AddCharset ISO-8859-3 .iso8859-3 .latin3
AddCharset ISO-8859-4 .iso8859-4 .latin4
AddCharset ISO-8859-5 .iso8859-5 .cyr .iso-ru
AddCharset ISO-8859-6 .iso8859-6 .arb .arabic
AddCharset ISO-8859-7 .iso8859-7 .grk .greek
AddCharset ISO-8859-8 .iso8859-8 .heb .hebrew
AddCharset ISO-8859-9 .iso8859-9 .latin5 .trk
AddCharset ISO-8859-10 .iso8859-10 .latin6
AddCharset ISO-8859-13 .iso8859-13
AddCharset ISO-8859-14 .iso8859-14 .latin8
AddCharset ISO-8859-15 .iso8859-15 .latin9
AddCharset ISO-8859-16 .iso8859-16 .latin10
AddCharset ISO-2022-JP .iso2022-jp .jis
AddCharset ISO-2022-KR .iso2022-kr .kis
AddCharset ISO-2022-CN .iso2022-cn .cis
AddCharset Big5 .Big5 .big5 .b5
AddCharset cn-Big5 .cn-big5
AddCharset WINDOWS-1251 .cp-1251 .win-1251
AddCharset CP866 .cp866
AddCharset KOI8 .koi8
AddCharset KOI8-E .koi8-e
AddCharset KOI8-r .koi8-r .koi8-ru
AddCharset KOI8-U .koi8-u
AddCharset KOI8-ru .koi8-uk .ua
AddCharset ISO-10646-UCS-2 .ucs2
AddCharset ISO-10646-UCS-4 .ucs4
AddCharset UTF-7 .utf7
AddCharset UTF-8 .utf8
AddCharset UTF-16 .utf16
AddCharset UTF-16BE .utf16be
AddCharset UTF-16LE .utf16le
AddCharset UTF-32 .utf32
AddCharset UTF-32BE .utf32be
AddCharset UTF-32LE .utf32le
AddCharset euc-cn .euc-cn
AddCharset euc-gb .euc-gb
AddCharset euc-jp .euc-jp
AddCharset euc-kr .euc-kr
AddCharset EUC-TW .euc-tw
AddCharset gb2312 .gb2312 .gb
AddCharset iso-10646-ucs-2 .ucs-2 .iso-10646-ucs-2
AddCharset iso-10646-ucs-4 .ucs-4 .iso-10646-ucs-4
AddCharset shift_jis .shift_jis .sjis
AddHandler cgi-script .cgi .pl
AddHandler type-map var
AddType text/html .shtml
AddOutputFilter INCLUDES .shtml
</IfModule>
Quote:
cat /etc/apache2/sites-available/default | sed '/ *#/d; /^ *$/d'
<VirtualHost *:80>
ServerAdmin webmaster@kadalur.com
DocumentRoot /var/www
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory /var/www/>
Options FollowSymLinks ExecCGI
AllowOverride All
Order allow,deny
allow from all
</Directory>
<Directory /var/www/squid-reports/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
AuthType Basic
AuthName "Authorised users only"
AuthUserFile /etc/sarg/.sarg_users
require valid-user
allow from all
</Directory>
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/access.log combined
Alias /doc/ "/usr/share/doc/"
<Directory "/usr/share/doc/">
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
Allow from 127.0.0.0/255.0.0.0 ::1/128
</Directory>
</VirtualHost>
Quote:
cat /etc/apache2/conf.d/SquirrelMail.conf | sed '/ *#/d; /^ *$/d'
Alias /webmail /usr/share/squirrelmail
<Location /webmail>
Order Deny,Allow
Deny from all
Allow from 192.168.0.0/24
</Location>
I am able to browse even from other machines using IP address and domain name. But not for webmail. If I give 192.168.0.1/webmail, this time it giving unable to connect error as in the attachement. So please help me to fix the squirrelmail problem.


Quote:
Originally Posted by bathory View Post
Hi,

In the very first lines of the guide you followed, it says to add index.php in the DirectoryIndex directive.
Have you done that?
Attached Thumbnails
Click image for larger version

Name:	error.png
Views:	17
Size:	68.8 KB
ID:	8426   Click image for larger version

Name:	working.png
Views:	14
Size:	117.4 KB
ID:	8427  
 
Old 11-20-2011, 12:11 PM   #4
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Quote:
I am able to browse even from other machines using IP address and domain name. But not for webmail. If I give 192.168.0.1/webmail, this time it giving unable to connect error as in the attachement. So please help me to fix the squirrelmail problem.
It doesn't make sense. If you can visit http://192.168.0.1 then you should be able to visit also http://192.168.0.1/webmail.

The "Forbidden" error you mentioned in your 1st post could be explained by the lack of the index.php in the DirectoryIndex option, or by the Allow/Deny directives or even by the webmail directory/file permissions.
The fact that you can connect to 192.168.0.1 but not to 192.168.0.1/webmail is a totally different thing.
You should clear you browser cache and try again, or use a different browser.

Regards
 
1 members found this post helpful.
Old 11-20-2011, 08:20 PM   #5
loveulinux
Member
 
Registered: Aug 2011
Posts: 68

Original Poster
Rep: Reputation: Disabled
I added index.php please see the below file. or should I add it in some other file? if yes I request you to mention the filename with more guidance.
Quote:
cat /etc/apache2/conf.d/SquirrelMail.conf | sed '/ *#/d; /^ *$/d'
Alias /webmail /usr/share/squirrelmail
<Location /webmail>
DirectoryIndex index.php
Order Deny,Allow
Deny from all
Allow from 192.168.0.0/24
</Location>
Quote:
or even by the webmail directory/file permissions.

ls -l /usr/share/squirrelmail/
total 48
drwxr-xr-x 5 www-data www-data 4096 2011-11-19 20:25 class
lrwxrwxrwx 1 www-data www-data 17 2011-11-19 20:25 config -> /etc/squirrelmail
drwxr-xr-x 4 www-data www-data 4096 2011-11-19 20:25 functions
drwxr-xr-x 29 www-data www-data 4096 2011-11-19 20:25 help
drwxr-xr-x 2 www-data www-data 4096 2011-11-19 20:25 images
drwxr-xr-x 3 www-data www-data 4096 2011-11-19 20:25 include
-rwx-r-x-r-x- 1 www-data www-data 671 2010-01-25 08:17 index.php
drwxr-xr-x 53 www-data www-data 4096 2011-11-19 20:25 locale
drwxr-xr-x 22 www-data www-data 4096 2011-11-19 20:25 plugins
drwxr-xr-x 2 www-data www-data 4096 2011-11-19 20:25 po
drwxr-xr-x 12 www-data www-data 4096 2011-11-19 21:54 squirrelmail
drwxr-xr-x 2 www-data www-data 4096 2011-11-19 20:25 src
drwxr-xr-x 3 www-data www-data 4096 2011-11-19 20:25 themes
I have already recursively changed the ownership and group to www-data. I request you to review my configuration files and let me know in which file I have to add index.php. Since I am newbie in apache I request you to mention sample configurations. I also cleared cache from the browser, restarted apache service and retried "192.168.0.1/webmail". But still I am facing the same error i.e "unable to connect
 
Old 11-21-2011, 01:01 AM   #6
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Hi,

What you have done above is useful only if you get a "Forbidden" error, that is not the case here.
In your case you say you can't connect to 192.168.0.1/webmail while you can connect to 192.168.0.1/, which doesn't make sense, as it rules out any kind of connectivity and/or firewall problems.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
squirrelmail problem mandyapenguin Linux - Newbie 1 11-20-2011 02:34 AM
[SOLVED] squirrelmail problem uppalagayatri Linux - Software 1 04-29-2011 09:25 AM
problem with squirrelmail mrlinux2000 Linux - Software 9 03-10-2008 09:59 AM
Squirrelmail problem gubak Linux - General 3 06-07-2007 12:33 AM
Squirrelmail problem gubak Linux - Networking 1 03-31-2006 08:42 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:14 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration