• 24-08-2007, 17:36:31
    #19
    Kurumsal PLUS
    http açıkmı yoksa kapalımı buna

    httpd status

    komudu ile bakalım..

    [root@tr21 ~]# httpd status

    Not Found

    The requested URL /server-status was not found on this server.

    Additionally, a 404 Not Found error was encountered while trying to use an
    ErrorDocument to handle the request.
    __________________________________________________ _______________


    Apache/1.3.37 Server at tr21.fxxx.net Port 80
    [root@tr21 ~]# killall httpd
    [root@tr21 ~]# httpd status

    Looking up localhost
    Making HTTP connection to localhost
    Sending HTTP request.
    HTTP request sent; waiting for response.
    Retrying as HTTP0 request.
    Looking up localhost
    Making HTTP connection to localhost
    Alert!: Unable to connect to remote host.

    lynx: Can't access startfile Apache Status


    ilk yaptıgımda 404 hatası verdi yani httpd çalışıyor sonrasında ise killall httpd yazdım ve tekrar httpd status yazdım ve çalışmıyor...

    bu kodu kullanmak


    şu şekilde kısalttım uygunmudur..

    Alıntı
    [root@tr21 ~]# httpd status | grep Port
    Apache/1.3.37 Server at tr21.xxxxxx.net Port 80
    [root@tr21 ~]# killall httpd
    [root@tr21 ~]# httpd status | grep Port

    Looking up localhost
    Making HTTP connection to localhost
    Alert!: Unable to connect to remote host.

    lynx: Can't access startfile Apache Status
  • 24-08-2007, 17:40:41
    #20
    bu şekilde 27015 portuna nasıl bakacağımki ?
  • 24-08-2007, 17:44:52
    #21
    Kurumsal PLUS
    bu şekilde sadece apache nin çalışıp çalışmadıgına bakacaksın portlara ssh dan netstat dan bakacaz...

    senin amacın acaba cs lerde insan varmı yada yokmu değilmi....

    onun için şunu kullanabiliriz.

    netstat -nap | grep :27015 | awk '{print $4}' | cut -d: -f1 | sort | uniq -c | sort -n

    bunun çıktısı sunucunda yer alan iplere 27015 den kaç kişi bağlanmış göstermek...

    port içinde ben bunu düşündüm hem cs lerin çalışıp çalışmadıgına hemde iplerdeki insan sayısına bakabileceksin.. saldırı alan ip inanılmaz derece fazla kişi bağlı olarak gösterecek..

    son port işi içinde bunu kullanalım tamam diyorsan scripti yazıyorum
  • 24-08-2007, 18:19:10
    #22
    netstat -nap | grep :27015 | awk '{print $4}' | cut -d: -f1 | sort | uniq -c | sort -n

    evet u komut gayet iyi çalışıyor açık serverları gösteriyor.
  • 24-08-2007, 18:30:05
    #23
    Onurss adlı üyeden alıntı: mesajı görüntüle
    [root@server ~]# alayinarestart
    Restart Baslasinnnnn....
    Shutting down MySQL...                                     [  OK  ]
    Starting MySQL                                             [  OK  ]
    Stopping named:                                            [  OK  ]
    Starting named:                                            [  OK  ]
    Shutting down clamd:                                       [  OK  ]
    Shutting down exim:                                        [  OK  ]
    Shutting down antirelayd:                                  [  OK  ]
    Shutting down spamd:                                       [  OK  ]
    Starting clamd:                                            [  OK  ]
    Starting exim:                                             [  OK  ]
    Starting exim-smtps:                                       [  OK  ]
    Starting antirelayd:                                       [  OK  ]
    Starting spamd:                                            [  OK  ]
    /etc/init.d/httpd restart: httpd restarted
    pure-ftpd: unrecognized service
    Restart islemleri tamamlandi...
    [root@server ~]#
    Tamamdır..Biraz daha düşünelim


    bende daha az komut çalıştırdı sunucu linux fedora5
    Alıntı
    Restart Baslasinnnnn....
    mysql: unrecognized service
    Stopping named: [ OK ]
    Starting named: [ OK ]
    exim: unrecognized service
    Stopping httpd: [ OK ]
    Starting httpd: [ OK ]
    pure-ftpd: unrecognized service
    Restart islemleri tamamlandi...
  • 24-08-2007, 18:44:03
    #24
    Alt alan adı oluşturmak.
    Mail oluşturmak.

    Bunları merak ediyorum doğrusu.
  • 24-08-2007, 18:51:30
    #25
    Kurumsal PLUS
    Zupermen sıranı bekleeee..

    #/usr/bin/!
    echo
    echo "Merhaba ben Durumcan sana serverinin ne durumda oldugunu bilgilendirmek icin yaziyorum.."
    echo
    echo "CPU Load ve Ram Kullanimlari"
    echo "------------------------------------------------"
    echo
    top -b -n 1 | head -n 10
    echo
    echo "------------------------------------------------"
    echo
    echo "Apache durumunuz"
    echo "------------------------------------------------"
    echo
    httpd status | grep Port
    echo
    echo "------------------------------------------------"
    echo
    echo "IP ve Portlarin durumu.."
    echo "------------------------------------------------"
    echo
    netstat -nap | grep :27015 | awk '{print $4}' | cut -d: -f1 | sort | uniq -c | sort -n
    echo
    echo "------------------------------------------------"
    echo
    echo "Saygilar iyi calismalar optum..."
    shellscript bu...

    nano /usr/bin/durumlar

    yazıp içine bunları yapıştır daha sonra

    chmod +x /usr/bin/durumlar

    ssh da durumlar yaz sonuçlar çıksın
  • 24-08-2007, 18:55:48
    #26
    Kurumsal PLUS
    benikaydet adlı üyeden alıntı: mesajı görüntüle
    bende daha az komut çalıştırdı sunucu linux fedora5
    which mysql
    ve
    which mysqld

    yaz ssh da çıktıları göster...
  • 24-08-2007, 18:57:00
    #27
    Üyeliği durduruldu
    Ni-Osman adlı üyeden alıntı: mesajı görüntüle
    Zupermen sıranı bekleeee..

    #/usr/bin/!
    echo
    echo "Merhaba ben Durumcan sana serverinin ne durumda oldugunu bilgilendirmek icin yaziyorum.."
    echo
    echo "CPU Load ve Ram Kullanimlari"
    echo "------------------------------------------------"
    echo
    top -b -n 1 | head -n 10
    echo
    echo "------------------------------------------------"
    echo
    echo "Apache durumunuz"
    echo "------------------------------------------------"
    echo
    httpd status | grep Port
    echo
    echo "------------------------------------------------"
    echo
    echo "IP ve Portlarin durumu.."
    echo "------------------------------------------------"
    echo
    netstat -nap | grep :27015 | awk '{print $4}' | cut -d: -f1 | sort | uniq -c | sort -n
    echo
    echo "------------------------------------------------"
    echo
    echo "Saygilar iyi calismalar optum..."
    shellscript bu...

    nano /usr/bin/durumlar

    yazıp içine bunları yapıştır daha sonra

    chmod +x /usr/bin/durumlar

    ssh da durumlar yaz sonuçlar çıksın
    bu yazdıkların benim sorumun cevabı değil dimi