Koozali.org: home of the SME Server

Obsolete Releases => SME Server 7.x => Topic started by: xboxer21 on February 18, 2008, 01:15:13 AM

Title: ProxyPass messed up
Post by: xboxer21 on February 18, 2008, 01:15:13 AM
Hello AllI,
I was trying to use proxypass to forward requests to another internal ip address and in the process I meesed up my squid (I Think), the internet stopped working and proxy pass didnt work either. how can fix squid also please let me know if I did anything wrong.

Here s how I tried using proxypass
Code: [Select]
db domains set /myapp/ domain Nameservers internet
db domains setprop /myapp/ ProxyPassTarget http://192.168.11.240/myapp/
db domains setprop /myapp/ TemplatePath ProxyPassVirtualHosts
signal-event domain-create /myapp/

since it did not work, I deleted it by executing the following command
Quote
signal-event domain-delete /myapp/

I tried restarting squid and its failing now :(
Quote
[root@server ~]# /etc/init.d/squid restart
Stopping squid:                                            [  OK  ]
Starting squid:                                            [FAILED]
[root@server ~]#


and now nobody in my offfice can access the internet. Please help

Thanks

Title: Re: ProxyPass messed up
Post by: pfloor on February 18, 2008, 07:24:48 AM
Did you delete the db entry?
db domains delete /myapp/

Squid is a supervised service, you should use the sv command?
sv d squid
sv u squid

If it doesn't work after deleting the db entry, you may need to reconfigure the server:
signal-event post-upgrade
signal-event reboot
Title: Re: ProxyPass messed up
Post by: cactus on February 18, 2008, 11:47:38 AM
Hello AllI,
I was trying to use proxypass to forward requests to another internal ip address and in the process I meesed up my squid (I Think), the internet stopped working and proxy pass didnt work either. how can fix squid also please let me know if I did anything wrong.

Here s how I tried using proxypass
Code: [Select]
db domains set /myapp/ domain Nameservers internet
db domains setprop /myapp/ ProxyPassTarget http://192.168.11.240/myapp/
db domains setprop /myapp/ TemplatePath ProxyPassVirtualHosts
signal-event domain-create /myapp/

Your syntax is incorrect please have a look at this: http://wiki.contribs.org/SME_Server:Documentation:FAQ#Proxy_Pass

You should not set the /myapp/ record but you should add the (sub)domain you want to proxy pass as record, the correct syntax is in the wiki page mentioned earlier in this post.
Title: Re: ProxyPass messed up
Post by: xboxer21 on February 18, 2008, 03:30:49 PM
Did you delete the db entry?
db domains delete /myapp/

Squid is a supervised service, you should use the sv command?
sv d squid
sv u squid

If it doesn't work after deleting the db entry, you may need to reconfigure the server:
signal-event post-upgrade
signal-event reboot

I ran the reconfigure commands, but no dice.
signal-event post-upgrade
signal-event reboot

Title: Re: ProxyPass messed up
Post by: xboxer21 on February 18, 2008, 03:34:01 PM
Your syntax is incorrect please have a look at this: http://wiki.contribs.org/SME_Server:Documentation:FAQ#Proxy_Pass

You should not set the /myapp/ record but you should add the (sub)domain you want to proxy pass as record, the correct syntax is in the wiki page mentioned earlier in this post.

I was using a contrib that used to allow me to add proxypass entries using server-manager , after upgrading to 7.3 I did not want to use that I wanted to use the command line options. and that contrib I was able to use /myapp/ entries. I will now create a subdomain entry and then use that now.

Thanks

Title: Re: ProxyPass messed up (SOLVED)
Post by: xboxer21 on February 19, 2008, 12:35:05 AM
I backed up everything and installed SME again. Its working fine now. Thanks for helping
Title: Re: ProxyPass messed up (SOLVED)
Post by: cactus on February 19, 2008, 08:08:19 AM
I backed up everything and installed SME again. Its working fine now. Thanks for helping
That would not have been necessary, you could have simply removed the offensive database entry and added the correct one, which should have also solved your problem.