Re: apache2 virtual host
On Mon, Feb 03, 2020 at 09:10:25AM -0500, Greg Wooledge wrote: On Mon, Feb 03, 2020 at 06:59:55AM +, Russell L. Harris wrote: I receive the following error message when attempting to enable a virtual host (apache2 in Debian 10): root@penelope:/etc/apache2/sites-available# a2ensite domain1.com.conf bash: a2ensite: command not found You used "su", right? https://wiki.debian.org/NewInBuster#Changes Yes, I used "su"; I was not aware of the change. Thanks, Greg. Mystery solved; issue resolved. Now back to the tutorial... RLH
Re: apache2 virtual host
On 2/3/2020 4:55 PM, Russell L. Harris wrote: > On Mon, Feb 03, 2020 at 07:42:12AM +, Andy Smith wrote: >> Does calling it as: >> >> # /usr/sbin/a2ensite ??? >> >> work? > > root@penelope:/usr/sbin# /usr/sbin/a2ensite > Your choices are: 000-default default-ssl domain1.com domain2.com > Which site(s) do you want to enable (wildcards ok)? > domain1.com > Enabling site domain1.com. > To activate the new configuration, you need to run: > systemctl reload apache2 > root@penelope:/usr/sbin# /usr/sbin/a2ensite domain2.com > Enabling site domain2.com. > To activate the new configuration, you need to run: > systemctl reload apache2 > root@penelope:/usr/sbin# systemctl reload apache2 > Job for apache2.service failed. > See "systemctl status apache2.service" and "journalctl -xe" for > details. > root@penelope:/usr/sbin# > Give us the output of the mention commands. -- John Doe
Re: apache2 virtual host
On Mon, Feb 03, 2020 at 07:42:12AM +, Andy Smith wrote: Does calling it as: # /usr/sbin/a2ensite ??? work? root@penelope:/usr/sbin# /usr/sbin/a2ensite Your choices are: 000-default default-ssl domain1.com domain2.com Which site(s) do you want to enable (wildcards ok)? domain1.com Enabling site domain1.com. To activate the new configuration, you need to run: systemctl reload apache2 root@penelope:/usr/sbin# /usr/sbin/a2ensite domain2.com Enabling site domain2.com. To activate the new configuration, you need to run: systemctl reload apache2 root@penelope:/usr/sbin# systemctl reload apache2 Job for apache2.service failed. See "systemctl status apache2.service" and "journalctl -xe" for details. root@penelope:/usr/sbin#
Re: apache2 virtual host
On Mon, 3 Feb 2020 07:40:25 + "Russell L. Harris" wrote: > On Mon, Feb 03, 2020 at 08:29:30AM +0100, john doe wrote: > >What is the content of your 'PATH' env? > > > >$ printf "%s\n" "$PATH" > > root@penelope:/usr/sbin# printf "%s\n" "$PATH" > /usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games > > I really must turn in for the night, and resume this on the morrow. > RLH > a2ensite just a different way to link /etc/apache2/sites-available/domain1.com.conf to /etc/apache2/sites-enabled/domain1.com.conf ln -s /etc/apache2/sites-available/domain1.com.conf /etc/apache2/sites-enabled/domain1.com.conf
Re: apache2 virtual host
On Mon, Feb 03, 2020 at 06:59:55AM +, Russell L. Harris wrote: > I receive the following error message when attempting to enable a > virtual host (apache2 in Debian 10): > >root@penelope:/etc/apache2/sites-available# a2ensite domain1.com.conf >bash: a2ensite: command not found You used "su", right? https://wiki.debian.org/NewInBuster#Changes
Re: apache2 virtual host
On Mon, Feb 03, 2020 at 08:29:30AM +0100, john doe wrote: What is the content of your 'PATH' env? $ printf "%s\n" "$PATH" root@penelope:/usr/sbin# printf "%s\n" "$PATH" /usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games I really must turn in for the night, and resume this on the morrow. RLH
Re: apache2 virtual host
On 2/3/2020 8:40 AM, Russell L. Harris wrote: > On Mon, Feb 03, 2020 at 08:29:30AM +0100, john doe wrote: >> What is the content of your 'PATH' env? >> >> $ printf "%s\n" "$PATH" > > root@penelope:/usr/sbin# printf "%s\n" "$PATH" > /usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games > In addition to Handy's answer, it is not in your path so you need to added there or to understand why /usr/sbin is not in your path. > I really must turn in for the night, and resume this on the morrow. It is morning here accross the pound! :) -- John Doe
Re: apache2 virtual host
Hi Russell, On Mon, Feb 03, 2020 at 07:11:21AM +, Russell L. Harris wrote: > On Mon, Feb 03, 2020 at 07:05:11AM +, Andy Smith wrote: > >(do these as root, since that seems to be how you are working) > > > ># which a2ensite > ># ls -la /usr/sbin/a2ensite > > root@penelope:/etc/apache2/sites-available# which a2ensite So a2ensite is either not present or not in your path… > root@penelope:/etc/apache2/sites-available# ls -la /usr/sbin/a2ensite > lrwxrwxrwx 1 root root 7 Oct 15 19:53 /usr/sbin/a2ensite -> a2enmod So a2ensite exists as a symlink to a2enmod. I'm guessing that however you became root ("su" instead of "su -" perhaps?) didn't leave you with /usr/sbin in your path. Does calling it as: # /usr/sbin/a2ensite … work? If not, what is the output of: # ls -la/usr/sbin/a2enmod Cheers, Andy -- https://bitfolk.com/ -- No-nonsense VPS hosting
Re: apache2 virtual host
On 2/3/2020 8:11 AM, Russell L. Harris wrote: > On Mon, Feb 03, 2020 at 07:05:11AM +, Andy Smith wrote: >> Hi Russell, >> >> On Mon, Feb 03, 2020 at 06:59:55AM +, Russell L. Harris wrote: >>> I receive the following error message when attempting to enable a >>> virtual host (apache2 in Debian 10): >>> >>> root@penelope:/etc/apache2/sites-available# a2ensite domain1.com.conf >>> bash: a2ensite: command not found >> >> Your shell is failing to find the "a2ensite" command. Normally it is >> found at /usr/sbin/a2ensite and is part of the apache2 package. What >> do the following commands say? >> >> (do these as root, since that seems to be how you are working) >> >> # which a2ensite >> # ls -la /usr/sbin/a2ensite > > root@penelope:/etc/apache2/sites-available# which a2ensite > > root@penelope:/etc/apache2/sites-available# ls -la /usr/sbin/a2ensite > lrwxrwxrwx 1 root root 7 Oct 15 19:53 /usr/sbin/a2ensite -> a2enmod > > root@penelope:/etc/apache2/sites-available# > > Thanks for the prompt response, Andy. It is an hour past midnight > here (central Texas), and I am about ready to pull the plug for the > night, but I would sleep better with this hurdle out of the way. > > No response to the first command. > What is the content of your 'PATH' env? $ printf "%s\n" "$PATH" -- John Doe
Re: apache2 virtual host
On Mon, Feb 03, 2020 at 07:05:11AM +, Andy Smith wrote: Hi Russell, On Mon, Feb 03, 2020 at 06:59:55AM +, Russell L. Harris wrote: I receive the following error message when attempting to enable a virtual host (apache2 in Debian 10): root@penelope:/etc/apache2/sites-available# a2ensite domain1.com.conf bash: a2ensite: command not found Your shell is failing to find the "a2ensite" command. Normally it is found at /usr/sbin/a2ensite and is part of the apache2 package. What do the following commands say? (do these as root, since that seems to be how you are working) # which a2ensite # ls -la /usr/sbin/a2ensite root@penelope:/etc/apache2/sites-available# which a2ensite root@penelope:/etc/apache2/sites-available# ls -la /usr/sbin/a2ensite lrwxrwxrwx 1 root root 7 Oct 15 19:53 /usr/sbin/a2ensite -> a2enmod root@penelope:/etc/apache2/sites-available# Thanks for the prompt response, Andy. It is an hour past midnight here (central Texas), and I am about ready to pull the plug for the night, but I would sleep better with this hurdle out of the way. No response to the first command.
Re: apache2 virtual host
Hi Russell, On Mon, Feb 03, 2020 at 06:59:55AM +, Russell L. Harris wrote: > I receive the following error message when attempting to enable a > virtual host (apache2 in Debian 10): > >root@penelope:/etc/apache2/sites-available# a2ensite domain1.com.conf >bash: a2ensite: command not found Your shell is failing to find the "a2ensite" command. Normally it is found at /usr/sbin/a2ensite and is part of the apache2 package. What do the following commands say? (do these as root, since that seems to be how you are working) # which a2ensite # ls -la /usr/sbin/a2ensite Cheers, Andy -- https://bitfolk.com/ -- No-nonsense VPS hosting
apache2 virtual host
I receive the following error message when attempting to enable a virtual host (apache2 in Debian 10): root@penelope:/etc/apache2/sites-available# a2ensite domain1.com.conf bash: a2ensite: command not found The configuration file domain1.com.conf is owned by root:root and has permissions identical to those of 000-default.conf . The man page for a2ensite prints, so I do not understand why bash cannot find the command. I have tried (without success): # a2ensite domain1 # a2ensite domain1.com # a2ensite domain1.com.conf
Splitting out apache2 virtual host bandwidth usage
Just been monitoring a new server - it has several apache2 virtual hosts and ntop is reporting within the last day 250M bandwidth usage on http alone. I know I can see on the awstats graph for each host the usage there. But - is there a simple way to either get ntop to separate by virtual hosts (not sure if this kind of customization is available) or - some other way to collect this information on a graph showing http bandwidth by virtual host? Note - all are on the same IP (NameVirtualHost config in apache). Just curious - got a bit fed up with clicking thru large numbers of awstats reports :) Chris Searle [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Re: Splitting out apache2 virtual host bandwidth usage
On 10/01/2007 04:17 PM, Chris Searle wrote: I know I can see on the awstats graph for each host the usage there. But - is there a simple way to either get ntop to separate by virtual hosts (not sure if this kind of customization is available) or - some other way to collect this information on a graph showing http bandwidth by virtual host? Note - all are on the same IP (NameVirtualHost config in apache). The only way that I know of to separate out vhost traffic on the same IP is to grok apache logs - this is exactly what awstats is doing for you. The only alternatives I can think of are looking at different web stats packages (they all process log files), or script out bandwidth usage from the various vhost logs or out of awstats to report the bandwidth data in the manner you want to see. -- Kind Regards, Michael Shuler -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Re: Splitting out apache2 virtual host bandwidth usage
On 2. okt. 2007, at 00.17, Michael Shuler wrote: http://cband.linux.pl/ http://mod-cband.com/cband-status Interesting - I will have to take a look at this. It's available in etch - I just need to see if it can be configured only for monitoring and not limiting (of course you can set extremely high limits so that they don't trigger :)) Chris Searle [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Re: Debian Etch apache2 virtual host problem
Hey all, Thank you very much for your help! I will go back and make the changes. Blessings, Rocky -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Debian Etch apache2 virtual host problem
Hey, I'm runing Debian etch with apache2 on it. To make the server host many website I added the following code to the end of /etc/apache2/ apache2.conf --Code begin-- NameVirtualHost * VirtualHost * # Basic setup ServerAdmin [EMAIL PROTECTED] ServerName www.workzone.com DocumentRoot /var/www/workzone/htdocs # HTML documents, with indexing. Directory / Options +Includes /Directory # CGI Handling ScriptAlias /cgi-bin/ /var/www/workzone/cgi-bin/ Location /cgi-bin Options +ExecCGI /Location # Logfiles ErrorLog /var/www/workzone/logs/error.log CustomLog /var/www/workzone/logs/access.log combined /VirtualHost -Code End The command apache2ctl configtest tells me [Fri Jan 01 11:55:20 1999] [warn] NameVirtualHost *:0 has no VirtualHosts Syntax OK And /etc/init.d/apache2 reload tells me [Fri Jan 01 11:56:30 1999] [warn] NameVirtualHost *:0 has no VirtualHosts How can I solve the problem please? Can any of you help me out? Blessings, Rocky -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Re: Debian Etch apache2 virtual host problem
# HTML documents, with indexing. Directory / Options +Includes /Directory this is extremely insecure if your machine is public see Order Deny, Allow # CGI Handling ScriptAlias /cgi-bin/ /var/www/workzone/cgi-bin/ Location /cgi-bin Options +ExecCGI /Location # Logfiles ErrorLog /var/www/workzone/logs/error.log CustomLog /var/www/workzone/logs/access.log combined /VirtualHost -Code End The command apache2ctl configtest tells me [Fri Jan 01 11:55:20 1999] [warn] NameVirtualHost *:0 has no VirtualHosts Syntax OK And /etc/init.d/apache2 reload tells me [Fri Jan 01 11:56:30 1999] [warn] NameVirtualHost *:0 has no VirtualHosts How can I solve the problem please? Can any of you help me out? I think you must define at least a directive for a virtual host inside your document root. Actually no pages can be served from your document root, there's not a web site definition but a cgi script alias, and you only get that warning instead of an error. Blessings, Rocky hope this helps raffaele
Re: Debian Etch apache2 virtual host problem
On Tue, Jul 31, 2007 at 09:30:38AM -, rocky wrote: Hey, I'm runing Debian etch with apache2 on it. To make the server host many website I added the following code to the end of /etc/apache2/ apache2.conf --Code begin-- NameVirtualHost * VirtualHost * # Basic setup ServerAdmin [EMAIL PROTECTED] ServerName www.workzone.com DocumentRoot /var/www/workzone/htdocs # HTML documents, with indexing. Directory / Options +Includes /Directory # CGI Handling ScriptAlias /cgi-bin/ /var/www/workzone/cgi-bin/ Location /cgi-bin Options +ExecCGI /Location # Logfiles ErrorLog /var/www/workzone/logs/error.log CustomLog /var/www/workzone/logs/access.log combined /VirtualHost -Code End The command apache2ctl configtest tells me [Fri Jan 01 11:55:20 1999] [warn] NameVirtualHost *:0 has no VirtualHosts Syntax OK you have not specified any virtual hosts. something like: VirtualHost 192.168.2.3:80 ServerName blah.foo.com DocumentRoot /var/www/root/of/blah CustomLog /var/log/apache2/access.log combined /VirtualHost would be in order with a different block with unique ServerName for each virtual host you want. see http://httpd.apache.org/docs/1.3/vhosts/name-based.html might be helpful A signature.asc Description: Digital signature
Apache2 / virtual host / htaccess et acces au htpasswd en relatif
bonjour, dans mon htacces je souhaiterais mettre le chemin du htpasswd en relatif (la racine de mes sites virtuels peut changer ) , mais cela ne semble pas accepté par apache (dans ce cas il recherche le htpasswd dans /etc !!!) ## .htaccess # AuthType Basic AuthUserfile ../.htpasswd AuthName reservé aux membres require valid-user # Si vous avez compris ma question, pouvez me donner une réponse pas trop complexe à mettre en oeuvre ? Merci d'avance Note config : Apache/2.0.55 sous etch
Re: Apache2 / virtual host / htaccess et acces au htpasswd en relatif
Salut, Je me penche actuellement sur cette histoire de htacces et htpasswd et je suis tombé sur cette page : http://www.toulouse-renaissance.net/c_outils/c_htaccess_htpasswd.htm Jette un oeil au 1°) et 3°), ça pourrait t'aiguiller. Bonne chance. AntoineLe 03/03/06, Bulot Grégory [EMAIL PROTECTED] a écrit : bonjour,dans mon htacces je souhaiterais mettre le chemin du htpasswd en relatif (laracine de messites virtuels peut changer ) , mais cela ne semble pasaccepté par apache (dans ce cas il recherche le htpasswd dans /etc !!!) ## .htaccess # AuthType Basic AuthUserfile ../.htpasswd AuthName reservé aux membres require valid-user # Si vous avez compris ma question, pouvez me donner une réponse pas tropcomplexe à mettre en oeuvre ?Merci d'avanceNote config :Apache/2.0.55 sous etch
Re: Apache2 / virtual host / htaccess et acces au htpasswd en relatif
Le Samedi 4 Mars 2006 02:32, Tonio F a écrit : Salut, Je me penche actuellement sur cette histoire de htacces et htpasswd et je suis tombé sur cette page : http://www.toulouse-renaissance.net/c_outils/c_htaccess_htpasswd.htm Jette un oeil au 1°) et 3°), ça pourrait t'aiguiller. Bonne chance. Antoine Merci c'est une page intéressante ! je 'gère' des pages d'ami(e)s sur free, lycos ce sera un bon aide mémoire pour moi. En ce qui me concerne, elle me confirme qu'il ne semble pas y avoir de possibilitées d'un htpasswd accessible en relatif (de manière simple). j'avais pensé à la génération en php du htaccess, mais il faudrait que je lance un cron tout les jours qui interroge chaque site ... et j'ai la flemme de le faire.