aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: unter Genoo ohne X mit Webgui  (Read 4462 times)

koolance

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 7
unter Genoo ohne X mit Webgui
« on: April 09, 2006, 12:05:25 PM »

Hi,
ich möchte am Montag aMuled mit Webinterface auf meinem Gentoo Server installieren. In der Installationsanleitung (http://www.amule.org/wiki/index.php/HowTo_Compile_In_Gentoo) steht es gibt Probleme und ich soll folgendes Ebuild verwenden: wxGTK-2.6.2-r2.ebuild
Allerdings schon ist schon die wxGTK-2.6.3 draußen. Jetzt weiß ich nicht ob ich einfach den Standartweg gehen kann weil der Fehler in 2.6.3 schon raus ist oder ob ich das alte Ebuild installieren soll.
Ich muß noch dazuschreiben das ich ein Linuxanfänger bin.
« Last Edit: April 09, 2006, 12:05:57 PM by koolance »
Logged

stefanero

  • Some Support
  • Developer
  • Hero Member
  • *****
  • Karma: 8
  • Offline Offline
  • Posts: 4235
Re: unter Genoo ohne X mit Webgui
« Reply #1 on: April 09, 2006, 03:33:27 PM »

gentoo hat noch kein ebuild für wx-2.6.3 also einfach das nehmen...
Logged
In its default setup, Windows XP on the Internet amounts to a car
parked in a bad part of town, with the doors unlocked, the key in
the ignition and a Post-It note on the dashboard saying, "Please
don't steal this."

koolance

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 7
Re: unter Genoo ohne X mit Webgui
« Reply #2 on: April 10, 2006, 07:30:36 PM »

Ich hatte eigentlich auf eine andere Antwort gehofft ;)  Ich glaube das wxGTK-2.6.2-r2.ebuild ist noch nicht im Portage Tree, wie kriege ich es installiert?

Im Bug-Report habe ich nur diese Info gefunden:
[goute]Note that for installing, you need to copy the
/usr/portage/x11-libs/wxGTK/files directory into your overlay as well, it
contains the patches necessary for the -r1 ebuild in portage.[/quote]

Das hilft mir leider nicht wirklich weiter.
Vielleicht hast du ja noch einen Tip für mich :)
Logged

stefanero

  • Some Support
  • Developer
  • Hero Member
  • *****
  • Karma: 8
  • Offline Offline
  • Posts: 4235
Re: unter Genoo ohne X mit Webgui
« Reply #3 on: April 11, 2006, 01:54:17 AM »

also wenn du es ganz einfach machen willst,
kopier das ebuild einfach in das
/usr/portage/x11-libs/wxGTK verzeichniss über das r1 ebuidl drüber

und machst

ebuild wxGTK-2.6.2-r2.ebuild digest

dannach dann

emerge BLABAL usw...dann sollt er eigentlcih das 2.6.2-r2 nehmen, das siehst ja dann beim updaten...
Logged
In its default setup, Windows XP on the Internet amounts to a car
parked in a bad part of town, with the doors unlocked, the key in
the ignition and a Post-It note on the dashboard saying, "Please
don't steal this."

koolance

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 7
Re: unter Genoo ohne X mit Webgui
« Reply #4 on: April 12, 2006, 08:08:23 PM »

Hat leider nicht geklappt, ich konnte wxgtk wie folgt installieren:
# USE="-X -gnome -gtk2 -opengl -sdl -wxgtk1" emerge -v wxGTK

Allerdings ist der aMule in meinem Portage-Tree trotz Sync immer nur  2.0.3-r4.
Ich hatte im System den "hardened" Flag an. Habe ihn jetzt allerdings raus genommen. Die ältere Version wäre mir vom Prinzip her egal, aber sobald ich probiere aMule zu installieren:

# USE="-X" emerge amule

Kommt folgende Fehlermeldung (in der Sogar die neue Versiojn von aMule ist):
server ~ # USE="-X" emerge amule
Calculating dependencies ...done!
>>> emerge (1 of 1) net-p2p/amule-2.0.3-r4 to /
>>> md5 files   ;-) amule-2.0.3-r4.ebuild
>>> md5 files   ;-) amule-2.1.0-r1.ebuild
>>> md5 files   ;-) amule-2.1.1.ebuild
>>> md5 files   ;-) amule-2.0.1-r2.ebuild
>>> md5 files   ;-) files/amuled.confd
>>> md5 files   ;-) files/amuled.initd
>>> md5 files   ;-) files/amuleweb.confd
>>> md5 files   ;-) files/amuleweb.initd
>>> md5 files   ;-) files/digest-amule-2.0.1-r2
>>> md5 files   ;-) files/digest-amule-2.0.3-r4
>>> md5 files   ;-) files/digest-amule-2.1.1
>>> md5 files   ;-) files/digest-amule-2.1.0-r1
>>> md5 src_uri ;-) aMule-2.0.3.tar.bz2
!!! set-wxconfig: Error:  Can't find normal or debug version:
!!! set-wxconfig:         /usr/lib/wx/config/gtk2-ansi-release-2.6 not found
!!! set-wxconfig:         /usr/lib/wx/config/gtk2-ansi-debug-2.6 not found
!!! You need to emerge wxGTK with gtk2 in your USE

Also habe ich noch einmal folgendes probiert:
# USE="-X -gnome gtk2 -opengl -sdl -wxgtk1" emerge -v wxGTK

Allerdings kommt nun diese Fehlermeldung:

 * Please re-emerge x11-libs/cairo with the png and X USE flags set

!!! ERROR: x11-libs/pango-1.10.3 failed.

Alledrings hilft mir das leider überhaupt nicht da ich ja kein X installieren möchte :(
Logged

stefanero

  • Some Support
  • Developer
  • Hero Member
  • *****
  • Karma: 8
  • Offline Offline
  • Posts: 4235
Re: unter Genoo ohne X mit Webgui
« Reply #5 on: April 12, 2006, 08:30:04 PM »

amule hat kein -X als use flag , selbst die aktuelle version nicht!

Calculating dependencies... done!
[ebuild   R   ] net-p2p/amule-2.1.1  USE="gtk nls unicode -amuled -debug -remote -stats" 3,186 kB


gibt 2varianten

a) bugreport http://bugs.gentoo.org

b) http://www.amule.org/wiki/index.php/HowTo_Compile_aMuled

^^selber machen..müsstest eigentlcih wxGTK teil weglassen können
da du das ja schon haben solltest...

gruss
Logged
In its default setup, Windows XP on the Internet amounts to a car
parked in a bad part of town, with the doors unlocked, the key in
the ignition and a Post-It note on the dashboard saying, "Please
don't steal this."

koolance

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 7
Re: unter Genoo ohne X mit Webgui
« Reply #6 on: April 13, 2006, 08:51:33 PM »

Ich bin wieder erwarten doch weiter gekommen. Der ich habe den Amuledaemon wie folgt installiert bekommen.

USE="nls amuled remote -gtk"

Der Amule Daemon läuft auch schon, jetzt muss ich nur noch amuleweb ans laufen kriegen...
Logged

stefanero

  • Some Support
  • Developer
  • Hero Member
  • *****
  • Karma: 8
  • Offline Offline
  • Posts: 4235
Re: unter Genoo ohne X mit Webgui
« Reply #7 on: April 14, 2006, 08:54:38 AM »

Logged
In its default setup, Windows XP on the Internet amounts to a car
parked in a bad part of town, with the doors unlocked, the key in
the ignition and a Post-It note on the dashboard saying, "Please
don't steal this."

koolance

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 7
Re: unter Genoo ohne X mit Webgui
« Reply #8 on: April 18, 2006, 05:54:57 PM »

Ich habe den Amuleweb auch noch ans laufen bekommen :)
Quote
dominik@server ~/.aMule $ amuleweb

Creating client...
Now, doing connection....
Using host 'server.homenetwork' port: 4712
Trying to connect (timeout = 10 sec)...
Succeeded! Connection established to aMule 2.0.3

---------------------------------
|       aMule Web Server        |
---------------------------------


Use 'Help' for command list

Web Server: Started
aMuleweb$
WSThread: Thread started
WSThread: created service
WSThread: created socket listening on :4711


Jetzt habe ich nur noch das Problem das ich nicht drauf connecten kann. Ich bin mir nicht sicher ob es an meinem Firewall liegt (iptables). Das Firewall  Howto geht leider nicht auf Amuleweb ein. Hast du vielleicht noch eine Regel übrig? :)
Logged

stefanero

  • Some Support
  • Developer
  • Hero Member
  • *****
  • Karma: 8
  • Offline Offline
  • Posts: 4235
Re: unter Genoo ohne X mit Webgui
« Reply #9 on: April 18, 2006, 06:49:23 PM »

kannst nich auf 4711 connecten oder kannst nicht einloggen?

zu den firewall regeln, nimm das howto und ersetze 4662 mit 4711....
Logged
In its default setup, Windows XP on the Internet amounts to a car
parked in a bad part of town, with the doors unlocked, the key in
the ignition and a Post-It note on the dashboard saying, "Please
don't steal this."

koolance

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 7
Re: unter Genoo ohne X mit Webgui
« Reply #10 on: April 18, 2006, 07:03:45 PM »

Mein Hauptrechner kann nicht Connecten. Auf dem Server ist der Amuleweb erreichbar (habe es mit wget ausprobiert).

IP-Server: 192.168.0.1
Hauptrechner: 192.168.0.2


Ich habe jetzt folgende Regeln hinzugefügt:
Quote
iptables -t nat -A PREROUTING -i ppp0 -p tcp --destination-port 4711 -j DNAT --to-destination 192.168.0.1:4711
server ~ # iptables -t nat -A PREROUTING -i ppp0 -p tcp --destination-port 4711 -j DNAT --to-destination 192.168.0.2:4711
server ~ # iptables -t nat -A PREROUTING -i eth0 -p tcp --destination-port 4711 -j DNAT --to-destination 192.168.0.2:4711
server ~ # iptables -t nat -A PREROUTING -i eth0 -p tcp --destination-port 4711 -j DNAT --to-destination 192.168.0.1:4711
server ~ # iptables -A FORWARD -i ppp0 -o eth0 -p tcp --dport 4711 -d 192.168.0.1 -j ACCEPT

Die Regeln haben aber leider nicht geholfen (sind ein paar mehr als nötig, aber ich was mir unsicher...)

EDIT
Habe übrigens noch folgende Regel für meinen auf meinem Hauptrechner laufenden Emule drin:
iptables -t nat -A PREROUTING -p tcp --dport 4662 -i ppp0 -j DNAT --to 192.168.0.2
« Last Edit: April 18, 2006, 07:15:15 PM by koolance »
Logged

stefanero

  • Some Support
  • Developer
  • Hero Member
  • *****
  • Karma: 8
  • Offline Offline
  • Posts: 4235
Re: unter Genoo ohne X mit Webgui
« Reply #11 on: April 18, 2006, 10:07:48 PM »

öhmm nat brauchst du nur wenn du vom internet aus auf einen server im Lan zugreifen willst...

sprich wenn auf deinem hauptrechner amuleweb laufen würde würdest du es brauchen.

du kannst die ganzen 4711 regeln eigentlcih kicken...

wenn du über das internet auf dein amuleweb zugreifen willst würde das einzige was du brauchst sein

iptables -A INPUT -p tcp --dport XX -j ACCEPT

weiter nix...von intern im Lan sind firewalls normalwerweise so eingestellt das sie alles zulassen.

wäre also geschickt wenn du mal das komplette firewall script postest...
Logged
In its default setup, Windows XP on the Internet amounts to a car
parked in a bad part of town, with the doors unlocked, the key in
the ignition and a Post-It note on the dashboard saying, "Please
don't steal this."

koolance

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 7
Re: unter Genoo ohne X mit Webgui
« Reply #12 on: April 19, 2006, 08:22:17 PM »

Ich habe folgende Regeln verwendet:
Quote
Zuerst löschen wir unsere aktuellen Regeln
# iptables -F
# iptables -t nat -F

Richten Sie das Standardverhalten für Pakete ein, auf die keine Regel zutrifft
# iptables -P INPUT ACCEPT
# iptables -P OUTPUT ACCEPT
# iptables -P FORWARD DROP

Kopieren Sie diese Beispiele ...
# export LAN=eth0
# export WAN=ppp0

Dann schränken wir unsere Dienste so ein, dass sie nur im LAN arbeiten
# iptables -I INPUT 1 -i ${LAN} -j ACCEPT
# iptables -I INPUT 1 -i lo -j ACCEPT
# iptables -A INPUT -p UDP --dport bootps -i ! ${LAN} -j REJECT
# iptables -A INPUT -p UDP --dport domain -i ! ${LAN} -j REJECT

(Optional) Erlauben Sie den Zugriff auf unseren SSH-Server aus dem WAN
# iptables -A INPUT -p TCP --dport ssh -i ${WAN} -j ACCEPT

Werfen Sie TCP/UDP-Pakete für privilegierte Ports weg
# iptables -A INPUT -p TCP -i ! ${LAN} -d 0/0 --dport 0:1023 -j DROP
# iptables -A INPUT -p UDP -i ! ${LAN} -d 0/0 --dport 0:1023 -j DROP

Schlussendlich fügen wir NAT-Regeln hinzu
# iptables -I FORWARD -i ${LAN} -d 192.168.0.0/255.255.0.0 -j DROP
# iptables -A FORWARD -i ${LAN} -s 192.168.0.0/255.255.0.0 -j ACCEPT
# iptables -A FORWARD -i ${WAN} -d 192.168.0.0/255.255.0.0 -j ACCEPT
# iptables -t nat -A POSTROUTING -o ppp0 -j MASQUERADE
Sagen Sie dem Kernel, dass IP-Forwarding in Ordnung ist
# echo 1 > /proc/sys/net/ipv4/ip_forward
# for f in /proc/sys/net/ipv4/conf/*/rp_filter ; do echo 1 > $f ; done

So müssen wir nach dem Booten die Regeln nicht per Hand starten
# /etc/init.d/iptables save
# rc-update add iptables default
# nano /etc/sysctl.conf
Fügen Sie die folgende Zeilen hinzu oder entfernen Sie die Kommentare:
net.ipv4.ip_forward = 1
net.ipv4.conf.default.rp_filter = 1

Bittorrent-Weiterleitung
# iptables -t nat -A PREROUTING -p tcp --dport 6881:6889 -i ${WAN} -j DNAT --to 192.168.0.2

eDonkey/eMule-Weiterleitung
# iptables -t nat -A PREROUTING -p tcp --dport 4662 -i ${WAN} -j DNAT --to 192.168.0.2

Ich ging eigentlich auch davon aus das von innen alles klappt :(

EDIT
Habe mal ausprobiert über einen Dyndnsprovider nach dem einfgen deiner Regel auf den Server zuzugreifen. Auch das hat nicht geklappt. Allerdings funktionierte der SSH Zugriff auf diesem Wege.

Danach habe ich noch Probiert amuleweb auf einem niedrigerem Port laufen zu lassen, aber folgendes passierte:
Quote
Web Server: Started
aMuleweb$
WSThread: Thread started
WSThread: created service
WSThread: could not create socket on :111

Auf dem Hohen Port wartert er aber eindeutig auf Antwort:
[qoute]Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name
tcp        0      0 0.0.0.0:4711            0.0.0.0:*               LISTEN      7225/amuleweb
tcp        0      0 0.0.0.0:4712            0.0.0.0:*               LISTEN      6638/amuled
tcp        0      0 0.0.0.0:53              0.0.0.0:*               LISTEN      6324/dnsmasq
tcp        0      0 0.0.0.0:4662            0.0.0.0:*               LISTEN      6614/amuled
tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN      6473/sshd
udp        0      0 0.0.0.0:1024            0.0.0.0:*                           6324/dnsmasq
udp        0      0 0.0.0.0:53              0.0.0.0:*                           6324/dnsmasq
udp        0      0 0.0.0.0:4665            0.0.0.0:*                           6614/amuled
udp        0      0 0.0.0.0:4672            0.0.0.0:*                           6614/amuled
udp        0      0 0.0.0.0:67              0.0.0.0:*    [/quote]

Die Iptables Regeln noch mal
Quote
server bin # iptables -t filter -v -L -n
Chain INPUT (policy ACCEPT 235K packets, 119M bytes)
 pkts bytes target     prot opt in     out     source               destination
  492 30899 ACCEPT     all  --  lo     *       0.0.0.0/0            0.0.0.0/0  
 317K   14M ACCEPT     all  --  eth0   *       0.0.0.0/0            0.0.0.0/0  
    0     0 REJECT     udp  --  !eth0  *       0.0.0.0/0            0.0.0.0/0           udp dpt:67 reject-with icmp-port-unreachable
    0     0 REJECT     udp  --  !eth0  *       0.0.0.0/0            0.0.0.0/0           udp dpt:53 reject-with icmp-port-unreachable
    5   244 ACCEPT     tcp  --  ppp0   *       0.0.0.0/0            0.0.0.0/0           tcp dpt:22
19697 1031K DROP       tcp  --  !eth0  *       0.0.0.0/0            0.0.0.0/0           tcp dpts:0:1023
  335 95820 DROP       udp  --  !eth0  *       0.0.0.0/0            0.0.0.0/0           udp dpts:0:1023
    0     0 ACCEPT     tcp  --  192.168.0.2 *       0.0.0.0/0            0.0.0.0/0           tcp dpt:4711
    0     0 ACCEPT     tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp dpt:4711
    0     0 ACCEPT     tcp  --  eth0   *       0.0.0.0/0            0.0.0.0/0           tcp dpt:4711 //Die hier habe ich ausversehen eingefügt, beim nächsten Neustart ist sie weg
    0     0 ACCEPT     tcp  --  ppp0   *       0.0.0.0/0            0.0.0.0/0           tcp dpt:4711


Chain FORWARD (policy DROP 259 packets, 16139 bytes)
 pkts bytes target     prot opt in     out     source               destination
  155  7484 DROP       all  --  eth0   *       0.0.0.0/0            192.168.0.0/16
  15M 5855M ACCEPT     all  --  eth0   *       192.168.0.0/16       0.0.0.0/0  
  16M   10G ACCEPT     all  --  ppp0   *       0.0.0.0/0            192.168.0.0/16
    0     0 ACCEPT     tcp  --  ppp0   eth0    0.0.0.0/0            192.168.0.1         tcp dpt:4711

Chain OUTPUT (policy ACCEPT 880K packets, 108M bytes)
 pkts bytes target     prot opt in     out     source               destination
« Last Edit: April 21, 2006, 07:37:58 PM by koolance »
Logged