Saturday, January 26, 2013

Failure when start service httpd on Fedora 18

hai guys, i try install Feodra 18
mmm.. when i try install and start service httpd on my fedora 18. i find problem when will start service httpd.

this tutorial i can share the solution for this problem.

when typing :
sudo service httpd start 

service respone and show this message :
Job for httpd.service failed. See 'systemctl status httpd.service' and 'journalctl -xn' for details.

you can check for the problem using :
sudo systemctl status httpd.service

and will show log:
httpd.service - The Apache HTTP Server
      Loaded: loaded (/usr/lib/systemd/system/httpd.service; enabled)
      Active: failed (Result: exit-code) since Sun 2013-01-27 00:26:20 WIT; 9s ago
     Process: 7518 ExecStop=/usr/sbin/httpd $OPTIONS -k graceful-stop (code=exited, status=0/SUCCESS)
     Process: 7516 ExecStart=/usr/sbin/httpd $OPTIONS -DFOREGROUND (code=exited, status=1/FAILURE)

and then,
sudo journalctl -xn

and will show log:
-- Unit httpd.service has failed.
-- The result is failed.
Jan 27 00:26:20 tkl systemd[1]: Unit httpd.service entered failed state
Jan 27 00:26:30 tkl systemd[1]: SELinux Got Sender :1.132
Jan 27 00:26:50 tkl yum[6634]: Installed: libmng-1.0.10-8.fc18.x86_64
Jan 27 00:26:51 tkl yum[6634]: Installed: kde-filesystem-4-42.fc18.x86_64
Jan 27 00:26:52 tkl yum[6634]: Installed: qt-settings-4.9-16.fc18.1.noarch
Jan 27 00:26:53 tkl sudo[7598]: drayanaindra : TTY=pts/1 ; PWD=/home/drayanaindra ; USER=root ; COMMAND=/bin/journalctl -xn

 now, you can cek your ServerName in /etc/httpd/conf/httpd.conf and config same with this :
ServerName localhost

cek your error log when will start your service using :
sudo tail -f /var/log/httpd/error_log 

and in my fedora show :
[Sun Jan 27 00:29:38.704621 2013] [core:notice] [pid 7770] SELinux policy enabled; httpd running as context system_u:system_r:httpd_t:s0
[Sun Jan 27 00:29:38.706668 2013] [suexec:notice] [pid 7770] AH01232: suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Sun Jan 27 00:29:39.201736 2013] [unique_id:alert] [pid 7770] (EAI 2)Name or service not known: AH01564: unable to find IPv4 address of "tkl"
AH00016: Configuration Failed


check your hostname in /etc/hostname

and  check your /etc/hosts, if in your configuration sam with this :        localhost.localdomain localhost

you can change with example :        localhost    tkl

now, edit  your SELINUX in /etc/selinux/config, SELINUX=disable
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
#     enforcing - SELinux security policy is enforced.
#     permissive - SELinux prints warnings instead of enforcing.
#     disabled - No SELinux policy is loaded.
# SELINUXTYPE= can take one of these two values:
#     targeted - Targeted processes are protected,
#     minimum - Modification of targeted policy. Only selected processes are protected.
#     mls - Multi Level Security protection.

now, you can try
sudo service httpd start 

and enjoy guys.. :) 


Tuesday, January 1, 2013

Install Sublime Text 2 via Repo (Fedora 17)

hi guys, now I'll try to share a tutorial on how to install Sublime Text via Repo in Fedora 17. Sublime Text is a text editor full power, because the sublime is a lot of support programming languages ​​such as C #, C + +, PHP, CSS, Lua, Python, Ruby, Rails, Java, HTML and many more. Okay, just us to tutoral installation.

going into a super user:
$ su

add repository :
# yum-config-manager --add-repo

enable the repo :
# yum-config-manager --enable

install sublime text :
# yum install sublime-text

i try this tutorial using fedora 17. you can try in another version fedora.
may be useful