Hot answers tagged

26

Yes, you can use visudo to edit those files. All that you have to do is specify the name of the file that you want to edit with the -f option. For example: visudo -f /etc/sudoers.d/somefilename Or, if needed: sudo visudo -f /etc/sudoers.d/somefilename Documentation From man visudo: -f sudoers Specify and alternate sudoers file location. ...


15

Mountain Lion removed the Web Sharing option, maybe you upgraded and had it running some time in the past? Anyway, you'll need to open Terminal for this: sudo killall httpd sudo launchctl unload /System/Library/LaunchDaemons/org.apache.httpd.plist The first will fail if you've already killed all the processes, the second disables startup.


14

Changes made to files in /etc/sudoers.d remain in place if you upgrade the system. This can prevent user lockouts when the system is upgraded. Ubuntu tends to like this behavior. Other distributions are using this layout as well. It has been my experience that the rules on files in this directory are looser than for /etc/sudoers. This has included: ...


12

why do we have /etc/sudoers.d? Because it's easier for automated tools (such as Chef or Puppet) to drop individual files into this directory, rather than making changes to /etc/sudoers, which might be fragile. The files in /etc/sudoers.d are (in effect) concatenated. You'll see several other instances of this pattern in /etc, such as /etc/cron.d and /etc/...


8

The problem occurs because Yosemite installs the latest version of Apache (2.4) whereas earlier versions of Mac OS X used Apache version 2.2 From the error, it appears that you were not using the standard version of PHP provided by Apple but a different version supplied by liip.ch. Removing the # sign as suggested by Nuttyx above will load the Apple ...


7

Try using rewrite rules if you have apache: RewriteEngine on RewriteRule ^/users/(.*)$ http://www.example.com/profiles/$1 [R=301,L] Note that you will need ModRewrite installed and enabled in your apache config. Pulled from here if you need a method for IIS.


7

The order is alphabetical. It only loads what the Include path specifies. In the case of Include conf.d/*.conf apache will load all files with names ending in .conf. This is an extract from Apache Documentation : Shell-style (fnmatch()) wildcard characters can be used to include several files at once, in alphabetical order. In addition, if Include ...


6

Please also note that the Yosemite installer overwrites the entire /private/etc/apache2/httpd.conf file with the new default Apache 2.4 configuration file. For example, if any Listen directives were added, they will have disappeared and need to be added again. E.g.: Listen 127.0.0.1:81 I found my old configuration in the following file, but due to ...


6

Shorter answer: You could simply erase or move the httpd.conf file you adjusted and then run the following command and it will be reinstalled: yum reinstall httpd Longer answer: But if you want to be a bit more methodical about it, you could follow the ideas and concepts shown on this page. First, check what package installed httpd.conf by running this ...


5

I've found out I was looking in the wrong place, the right path to httpd.conf for MAMP PRO is ~/Library/Application Support/appsolute/MAMP PRO.


4

Firefox is caching this resource. Clean your browser cache: Firefox -> Options -> Privacy -> Clear your recent history -> Tick checkbox for "Cache" -> OK. Plain and simple. For completeness, I'll also add that if you want to force a non-cached version of a page to be displayed, using Ctrl+F5 in most browsers will force one. In the case of redirect issues ...


4

On most versions of Windows httpd.exe has a default location of: C:\Program Files\Apache Software Foundation\Apache2.4\bin (Of course swap the 4.2 version number for whichever you may have installed)


3

Run config test [root@9001 conf_0.d]# /etc/init.d/httpd configtest Syntax OK Check what users and group set in httpd.conf User apache Group apache Disable SELinux if its enabled.


3

Let apache2 enable the module with the a2enmod command. This tool will help identify if there's any issues with you installed libphp5 module shell~> sudo a2enmod php5 shell~> sudo apachectl -M | grep php5 Syntax OK php5_module (shared) shell~> sudo /etc/init.d/httpd restart More info about enabling/disabling apach2 modules here


3

Don't believe everything you read on Wikipedia. Taken from a live, recently installed CentOS 6 system: The network is started in runlevels 2, 3, 4 and 5. # chkconfig --list network network 0:off 1:off 2:on 3:on 4:on 5:on 6:off As a practial matter, only runlevels 3 and 5 ever really get used. Runlevel 3 is the usual "no-graphical-...


3

I'm not sure why was it crashing, but by adding following line into mbp:~ alexus$ grep ^Alias /etc/apache2/users/alexus.conf Alias /~alexus/workspace /Users/alexus/workspace mbp:~ alexus$ did the trick...


3

.htaccess is used for setting access to a site. its not what you need - you need to look at mod rewrite rules or vhosts and setting the vhost document root to /var/www/blog the best starting point, naturally is apache's own docs, which i have linked to


3

It seems that you can fix this by removing the # at the beggining of the following line in /etc/apache2/httpd.conf file: LoadModule php5_module libexec/apache2/libphp5.so


3

Another benefit of using visudo -f as mentioned in some answers is there is a corresponding option -c or --check that verifies you don't have invalid information in a sudoers.d file or any other file you might want to put in sudoers.d. This is REALLY handy in the cases mentioned with automated tools, as you can run e.g. sudo visudo -c -q -f /home/myuser/...


3

If your RHEL 7 system has SELinux enforcing, you need to enable the SELinux boolean values to get NFS working. To check if your system is utilizing SELinux: # getenforce If the above returns enforcing, please continue: # getsebool -a | grep httpd_use_nfs If the above returns httpd_use_nfs --> off, run the following command to permanently allow ...


2

There is no uninstall provided by most make installed packages. On Ubuntu, the apache2 .deb package is installed: $ which apache2 /usr/sbin/apache2


2

I found a blog post that might help you http://farinspace.com/2010/02/php-error-faulting-module-name-php5ts/ Seems like your php installation might be the reason for your woes.


2

Apache provides a tool call "rotatelogs". It can be configured inside the httpd.conf file, so no need to schedule a tool to do the rotation. See this page for more information: rotatelogs - Piped logging program to rotate Apache logs


2

Another process is interfering with your timezone settings. There's a pretty concise answer to this at "what could cause Apache's time/timezone to change intermittently?". This can be particularly painful with Django -- as it doesn't handle juggling timezones very well -- and as such there are some good explanations in some Django-specific questions: Django ...


2

.htaccess isn't usually required. It is used for configuration directives that might otherwise need to be put in the httpd.conf file, and is especially useful in cases where you don't have access to the server configuration. At any rate, that probably isn't your problem. I suggest you review your httpd-error.log to see if the problem might be listed ...


2

Sounds like this is not an Apache issue, but like your index.html is using HTML frames. So, to get rid of this behavior, you'll have to get rid of the frames. Update, as this is your DNS provider adding those frames: If you have a fixed public IP address, then any normal DNS provider allows you to map your domain to some specific IP address, instead of ...


2

Unfortunately, it is very unlikely you'll be able to modify the settings on the router sufficiently to work around its existing firmware.


2

You could change your cache settings so that it checks for a new version of the page every time for all websites. Type into the address bar: about:config. Click to confirm that you want to edit the settings. Search for browser.cache.check_doc_frequency. Double-click the line. Change the value from 3 (default) to 1. For more details on this setting, see ...


2

Open the Sharing preference pane in System Preferences and uncheck Web Sharing.


2

Apache is the default user on Centos, assuming you installed from Yum. You can and should verify by looking in /etc/httpd/conf/httpd.conf. Are there other things going on with this Magento installation? Such as php suexec? php-fpm or php-cgi process? Also, the correct command would be sudo chown -R nobody.devs /path/to/magento To answer 1 and 2: Running ...



Only top voted, non community-wiki answers of a minimum length are eligible