Jump to content
Sign in to follow this  
gengstapo

[wta] Turbolinux10

Recommended Posts

silap..

sebenarnya apache belum up lagi..

yg tertera dalam command line tuh cuma command "grep apache" yg dimasukkan tadik..

Betul...itu grep apache bukan service apache...

Share this post


Link to post
Share on other sites

** so mcm maner nak wat nih? aku letak file index.html kat direktori "file:/var/www/html/index.html"

Ok .....kalo camtu...ko edit httpd.conf:

1)DocumentRoot /var/www/html

2)<Directory /var/www/html/>

Silap ko ialah ko pergi bubuh " " .

Lepas edit restart apache: service htppd restart

biggrin.gif

Edited by oshiri

Share this post


Link to post
Share on other sites

Ok .....kalo camtu...ko edit httpd.conf:

1)DocumentRoot /var/www/html

2)<Directory /var/www/html/>

Silap ko ialah ko pergi bubuh " " .

Lepas edit restart apache: service htppd restart

biggrin.gif

* wahh tima kasih la kat c-fuu oshiri & blank nih. dah berjaya aku membuat localhost punya web. tp, aku pelik skang, dia tak paparkan web tp paparkan coding HTML aku plaks. knaper erk?

Share this post


Link to post
Share on other sites

hehehee.. wehh gurus oshiri, yg prob tuh aku dah settle. salah coding daa. patut la bukak2 terus kuar coding html. aku nak tanya lagik nih, mcm sekarang pc windows aku dah boleh browse pc turbolinux aku nih. boleh tak kalau buat kan address dia tuh tukar kepada perkataan. cth sekarang, pc aku tuh ip dia 12.12.123.123, so pc windows aku pun kene taip ip tuh in order nak browse website dlm tuh. kalau aku guna perkataan boleh tak, mcm gengstapo.com ker aper ker?? biggrin.gif

Share this post


Link to post
Share on other sites

Yang ni panjang cerita dia plak.......

Cam kalo dari luar ko boleh register dengan no-ip atau dyndns untuk dapatkan dns untuk dynamic ip ko (ip wan/streamyx).

Tapi kalo dari dalam lan, kena la ada dns server....supaya setiap ip dalam lan tu ada nama sendiri.

Cara paling mudah dan tak perlukan dns server...ialah guna hostname. Aku tak tau apa hostname pc redhat tu....ko type: hostname dalam konsole, nanti dia kluar la nama apa.

Kalo perlu ubah nama hostname tu ko ubah la....kepada apa yang ko nak.

Contoh: gengstapo.com

Make sure la genstapo ni takder kat internet.

Nak senang jangan guna .com....guna yang karut jer.

Jadi dari local pc, selain dari guna: localhost atau 127.0.01...ko boleh guna hostname tu (gengstapo.com?)

Begitu juga dengan pc lain.....pc lain boleh akses webpage tu guna hostname pc redhat tu.

biggrin.gif

Share this post


Link to post
Share on other sites

Yang ni panjang cerita dia plak.......

Cam kalo dari luar ko boleh register dengan no-ip atau dyndns untuk dapatkan dns untuk dynamic ip ko (ip wan/streamyx).

Tapi kalo dari dalam lan, kena la ada dns server....supaya setiap ip dalam lan tu ada nama sendiri.

Cara paling mudah dan tak perlukan dns server...ialah guna hostname. Aku tak tau apa hostname pc redhat tu....ko type: hostname dalam konsole, nanti dia kluar la nama apa.

Kalo perlu ubah nama hostname tu ko ubah la....kepada apa yang ko nak.

Contoh: gengstapo.com

Make sure la genstapo ni takder kat internet.

Nak senang jangan guna .com....guna yang karut jer.

Jadi dari local pc, selain dari guna: localhost atau 127.0.01...ko boleh guna hostname tu (gengstapo.com?)

Begitu juga dengan pc lain.....pc lain boleh akses webpage tu guna hostname pc redhat tu.

biggrin.gif

* hurmmm.. aku tak baper paham la. tadi aku ader adjust localhost@localdomain tuh. so, kalau dr konsol boleh reset bagi default balik takk?

Share this post


Link to post
Share on other sites

Ko type kat konsole:

hostname

Apa yang keluar?

tu la nama hostname pc tu.

Kalo nak ubah hostname tu...ko kena edit dua file nih:

/etc/hosts

/etc/sysconfig/network

biggrin.gif

Share this post


Link to post
Share on other sites

aku dah buat mcm yg kat atas tuh, tp nih yg dipaparkan konsole aku :

[root@www root]# /etc/hosts

bash: /etc/hosts: Permission denied

[root@www root]# /etc/sysconfig/network

bash: /etc/sysconfig/network: Permission denied

[root@www root]# hostname

www

[root@www root]#

** hurmmm apa yg aku kene buat nih?? tak paham aku. yg aku pasti hostname aku dah jadik "www" betul takk?

Share this post


Link to post
Share on other sites

aku dah buat mcm yg kat atas tuh, tp nih yg dipaparkan konsole aku :

** hurmmm apa yg aku kene buat nih?? tak paham aku. yg aku pasti hostname aku dah jadik "www" betul takk?

ermm tuh ko bukan edit file.. tuh ko taip path ke file je... system pun tak paham apa ko nak.. ko nak edit ke.. delete ke.. create ke?

guna la editor mcm vi / pico / joe / nano / actually nih asas linux, sebelum nak masuk hal2 server ke apa2.. pasal tuh ( sorry ek? ) bila penah aku ckp kena belajo darik asas/bawah, ramai yg sanggah aku balik kata "dah pandai", "senang je" ( pakai GUI la actually ).. bila kita jumpa prob mcm nih then kita akan fhm smile.gif

Share this post


Link to post
Share on other sites

1. /etc/hosts :

# TurboLinux /etc/hosts table

# This file contains hostname/IP lookup information.

# This file is (usually) queried before DNS or NIS.

# Current /etc/hosts generated by turbonetcfg.

# Generated on: Thu Jun  2 06:23:21 2005

127.0.0.1  localdomain  localhost

# End of /etc/hosts

2. /etc/sysconfig/network :

NETWORKING=yes

PROFILENAME="No_Profile"

HOSTNAME=www

DOMAINNAME=dzul

GATEWAY=10.21.129.254

GATEWAYDEV=eth0

FORWARD_IPV4=no

IPX=no

TIMESERVERATBOOT=no

** hurmmm maner yg nak kene ubah nih?? sorry lerr pasal terus2 study pasal server. smile.gif

** aku dah ON httpd nih & dia boleh run dlm LAN, skang nak address nama(bukan IP pc) cthnya : www.mytest.net.my, boleh tak?

Edited by gengstapo2

Share this post


Link to post
Share on other sites

ok..dalam

1)/etc/host:

# TurboLinux /etc/hosts table
# This file contains hostname/IP lookup information.
# This file is (usually) queried before DNS or NIS.
# Current /etc/hosts generated by turbonetcfg.
# Generated on: Thu Jun  2 06:23:21 2005

127.0.0.1  genstapo2.net localhost
# End of /etc/hosts
2) /etc/sysconfig/network :
NETWORKING=yes
PROFILENAME="No_Profile"
HOSTNAME=gengstapo2.net
DOMAINNAME=dzul
GATEWAY=10.21.129.254
GATEWAYDEV=eth0
FORWARD_IPV4=no
IPX=no
TIMESERVERATBOOT=no
Tambah lagi satu file yg ko kena edit: 3) /etc/hostname:
gengstapo2.net

Make sure cuma satu line ni jer yg ada.

Siap. Reboot pc tu.

lepas ty type kat konsole utk makesure hostname berubah: hostname

output dia patutnya: gengstapo2.net

Sekarang dari browser cuma perlu type: http://gengstapo2.net

biggrin.gif

Share this post


Link to post
Share on other sites

hurmmm wehh dewa, aku dah buek tp tak dapek lerr. yg ko bagi tuh utk setting internet ker cuma dlm area LAN? kalau publish kat internet, aku rasa mcm tak lepas jek server aku nih. kalau utk LAN punya, setting mmg mcm tuh kerr? ph34r.gif

Share this post


Link to post
Share on other sites

Yang tu untuk persekitaran LAN.

Cuma pc dalam lan jer boleh akses guna hostname.

Kalo nak akses dari luar..........bergantung la.....kalo guna streamyx dynamic ip....ko kena la register dengan mana-mana dynamic dns service.

Contoh yang free: no-ip

http://www.no-ip.com/

Tapi ada condition yang ko kena patuhi:

Kalo guna router, ko kena buat portforwarding : port 80 ko forward ke ip pc redhat tu.

Kalo guna bridge modem dan server, make sure server tu redirect port 80 ke ip pc redhat.

Masalah dengan router ialah, pc dalam lan tak boleh akses webpage ko kalo guna address dari internet.

biggrin.gif

Share this post


Link to post
Share on other sites

hurmmm.. skang nih yg pc windows aku nih tak bulih akses web server dlm pc linux aku nih. kalau boleh pun kene pakai iP adrress pc linux baru bole nengok website aku nih. pc linux & pc windows aku nih dlm LAN yg sama & kedua2 sambung ke satu switch yg sama & switch tuh sebagai divider talian internet dari server utama. so, aku rasa mcm tak boleh jer atau aku yg tak reti nak setting nih?

Share this post


Link to post
Share on other sites

hurmmm.. skang nih yg pc windows aku nih tak bulih akses web server dlm pc linux aku nih. kalau boleh pun kene pakai iP adrress pc linux baru bole nengok website aku nih. pc linux & pc windows aku nih dlm LAN yg sama & kedua2 sambung ke satu switch yg sama & switch tuh sebagai divider talian internet dari server utama. so, aku rasa mcm tak boleh jer atau aku yg tak reti nak setting nih?

actually..

mmg tak boleh.. kalau tak senang la.. aku taruk server umah aku www.yahoo.com, terus org masuk internet ke www.yahoo.com pi umah aku... so sesapa pun boleh divert internet ke rumah depa kan?

actually domain ko belum registered.. camana la internet "nak kenal".. pasal tuh pakai ip je... nih berkaitan ngan DNS ( dah bab lain dah ). Pasal tuh org register domain bayar sampai kadang tuh beratus2.. hosting lg... apa2 lg la. kalau takat set hostname je terus jadik valid domain, takyah la upah sesapa smile.gif....

so far system ko dah jalan, web tuh ok.. so ko kene stadi bab nih plak la.. slow2 jgn gopoh...

Share this post


Link to post
Share on other sites

owhh.. ic. tu la sbb aku pun terfikir gaks, mcm mana web boleh carik iP aku nih kalau tetiber jek letak domain. dah tentu domain tuh mewakili ni iP sebenarkan? hehehee.. thanks to all dewa2 linux here. wink.gif

Share this post


Link to post
Share on other sites

hurmmm.. nak tanya lagik. kalau aku reboot pc linux aku nih, mcm mana nak setting supaya httpd automatic run after reboot??

Share this post


Link to post
Share on other sites

hurmmm.. nak tanya lagik. kalau aku reboot pc linux aku nih, mcm mana nak setting supaya httpd automatic run after reboot??

banyak cara.. ko leh set kat runlevel 3 tuh ( chkconfig ) untuk include apache run skali.. ataupun cara manual yg amat klasik.. taruk command untuk run apache kat /etc/rc.d/rc.local

Share this post


Link to post
Share on other sites

banyak cara.. ko leh set kat runlevel 3 tuh ( chkconfig ) untuk include apache run skali.. ataupun cara manual yg amat klasik.. taruk command untuk run apache kat /etc/rc.d/rc.local

* hurmm.. mcm maner nak edit tuh( chkconfig )? tuh file shell erkk? double klik tak bleh bukak pun. aku try bukak pakai aplication kEdit, kWrite, kate tapi dia paparkan simbol pelik2 mcm kita guna notepad buka file jpeg. ada cara lain takk? aku boleh bukak file /etc/rc.d/rc.local jek tp tak tau nak letak command aper. blink.gif

Share this post


Link to post
Share on other sites

Ni contoh dalam gentoo (tak tau distro lain sama ke tak):

rc-update add apache default

chkconfig tu ko taip chkconfig dalam konsole untuk run kalo tak silap aku.. taip man chkconfig untuk keterang lanjut..

Edited by b1naryc0de

Share this post


Link to post
Share on other sites

[root@anip root]# chkconfig

chkconfig version 1.3.8 - Copyright © 1997-2000 Red Hat, Inc.

This may be freely redistributed under the terms of the GNU Public License.

usage:  chkconfig --list [name]

        chkconfig --add <name>

        chkconfig --del <name>

        chkconfig [--level <levels>] <name> <on|off|reset>)

[root@anip root]# cd

[root@anip root]#

** hurmm.. cuba ajar mcm maner nak setting nih? nak buat supaya after reboot, web automatik start.

Share this post


Link to post
Share on other sites

** hurmm.. cuba ajar mcm maner nak setting nih? nak buat supaya after reboot, web automatik start.

#chkconfig <service> on/off
contoh
#chkconfog httpd on

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

×
×
  • Create New...