PDA

Archiv verlassen und diese Seite im Standarddesign anzeigen : phpsysinfo und apache



YoZ
16.05.04, 17:31
hallo leute,
habe auf meinem apache-server phpsysinfo 2.1 laufen.. alles läuft nur die PCI Devices werden auf der webinterface nicht angezeigt und werden so aufgelistet:

PCI Devices

PCI device 1106:0597
PCI device 1106:8598
PCI device 1106:0686
PCI device 1106:0571
PCI device 1106:3038
PCI device 1106:3057
PCI device 1106:3058
PCI device 1106:3106
PCI device 1002:5246

Hat jemand eine idee was da falsch ist und wie ich das ändern kann?

gruß, yoz

johnpatcher
16.05.04, 17:43
phpsysinfo liest die details auch nur aus "/proc/sonstwas" aus. den fehler wirst du wohl auf dieser "ebene" suchen müssen ...

johnpatcher

YoZ
16.05.04, 17:49
yeap das war mir klar..

naja habe suse laufen.. vielleicht kann mir jemand sagen wo diese info herausgelesen wird damit ich den pfad dementsprechend angeben kann..

gruß, yoz

johnpatcher
16.05.04, 17:53
schau dir doch mal den quellcod an (ist doch legal oder? ist ja opensource, denk ich , wenn net dann gleich löschen ....)


function pci () {
$results = array();

if ($fd = fopen('/proc/pci', 'r')) {
while ($buf = fgets($fd, 4096)) {
if (preg_match('/Bus/', $buf)) {
$device = 1;
continue;
}

if ($device) {
list($key, $value) = split(': ', $buf, 2);

if (!preg_match('/bridge/i', $key) && !preg_match('/USB/i', $key)) {
$results[] = preg_replace('/\([^\)]+\)\.$/', '', trim($value));
}
$device = 0;
}
}
}
return $results;
}


=> /proc/pci ...

öffne mal die datei mit vi.
"vim /proc/pci"

johnpatcher

YoZ
16.05.04, 17:58
ok /proc/pci sheint diese info zu haben.. wundert mich warum phpsysinfo nicht daraus die information entnimmt.. hmm würde gerne wissen wo dieser pfad anzugeben ist..

YoZ
16.05.04, 18:04
ich habe das hier der datei /sysinfo/includes/xml/hardware.php entnehmen können:

$sys = $sysinfo->cpu_info();

$ar_buf = $sysinfo->pci();

if (count($ar_buf)) {
for ($i=0;$i<sizeof($ar_buf);$i++) {
if ($ar_buf[$i]) {
$pci_devices .= " <Device>" . chop($ar_buf[$i]) . "</Device>\n";
}
}
}


ist das denn die richtige datei?
gruß, yoz

johnpatcher
16.05.04, 18:21
ähm, ich hab meinen code aus der datei: /phpsysinfo/includes/os/class.Linux.inc.php

und glaube das ist die richtige, weil hier auch das ganze andere zeug drinnensteht

johnpatcher

YoZ
16.05.04, 18:24
ich merke gerade das phpsysinfo richtig herausliest nur ist der inhalt der datei seltsam..


PCI devices found:
Bus 0, device 0, function 0:
Class 0600: PCI device 1106:0597 (rev 4).
Master Capable. Latency=16.
Prefetchable 32 bit memory at 0xd8000000 [0xdbffffff].
Bus 0, device 1, function 0:
Class 0604: PCI device 1106:8598 (rev 0).
Master Capable. No bursts. Min Gnt=12.
Bus 0, device 7, function 0:
Class 0601: PCI device 1106:0686 (rev 20).
Bus 0, device 7, function 1:
Class 0101: PCI device 1106:0571 (rev 6).
Master Capable. Latency=32.
I/O at 0xd000 [0xd00f].
Bus 0, device 7, function 2:
Class 0c03: PCI device 1106:3038 (rev 6).
IRQ 10.
Master Capable. Latency=32.
I/O at 0xd400 [0xd41f].
Bus 0, device 7, function 4:
Class 0600: PCI device 1106:3057 (rev 16).
IRQ 9.
Bus 0, device 7, function 5:
Class 0401: PCI device 1106:3058 (rev 18).
IRQ 9.
I/O at 0xd800 [0xd8ff].
I/O at 0xdc00 [0xdc03].
Bus 0, device 13, function 0:
Class 0200: PCI device 1106:3106 (rev 134).
IRQ 10.
Master Capable. Latency=32. Min Gnt=3.Max Lat=8.
I/O at 0xe400 [0xe4ff].
Non-prefetchable 32 bit memory at 0xe2000000 [0xe20000ff].
Bus 1, device 0, function 0:
Class 0300: PCI device 1002:5246 (rev 0).
IRQ 11.
Master Capable. Latency=32. Min Gnt=8.
Prefetchable 32 bit memory at 0xdc000000 [0xdfffffff].
I/O at 0xc000 [0xc0ff].
Non-prefetchable 32 bit memory at 0xe1000000 [0xe1003fff].
...skipping...
PCI devices found:
Bus 0, device 0, function 0:
Class 0600: PCI device 1106:0597 (rev 4).
Master Capable. Latency=16.
Prefetchable 32 bit memory at 0xd8000000 [0xdbffffff].
Bus 0, device 1, function 0:
Class 0604: PCI device 1106:8598 (rev 0).
Master Capable. No bursts. Min Gnt=12.
Bus 0, device 7, function 0:
Class 0601: PCI device 1106:0686 (rev 20).
Bus 0, device 7, function 1:
Class 0101: PCI device 1106:0571 (rev 6).
Master Capable. Latency=32.
I/O at 0xd000 [0xd00f].
Bus 0, device 7, function 2:
Class 0c03: PCI device 1106:3038 (rev 6).
IRQ 10.
Master Capable. Latency=32.
I/O at 0xd400 [0xd41f].
Bus 0, device 7, function 4:
Class 0600: PCI device 1106:3057 (rev 16).
IRQ 9.
Bus 0, device 7, function 5:
Class 0401: PCI device 1106:3058 (rev 18).
IRQ 9.
I/O at 0xd800 [0xd8ff].
I/O at 0xdc00 [0xdc03].
Bus 0, device 13, function 0:
Class 0200: PCI device 1106:3106 (rev 134).
IRQ 10.
Master Capable. Latency=32. Min Gnt=3.Max Lat=8.
I/O at 0xe400 [0xe4ff].
Non-prefetchable 32 bit memory at 0xe2000000 [0xe20000ff].
Bus 1, device 0, function 0:
Class 0300: PCI device 1002:5246 (rev 0).
IRQ 11.
Master Capable. Latency=32. Min Gnt=8.
Prefetchable 32 bit memory at 0xdc000000 [0xdfffffff].
I/O at 0xc000 [0xc0ff].
Non-prefetchable 32 bit memory at 0xe1000000 [0xe1003fff].

sollte das ganze denn nicht so aussehen:


S3 Inc. 86c764/765 [Trio32/64/64V+]
Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+
Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+ (#2)
Adaptec AHA-2940U/UW/D / AIC-7881U
Compaq Computer Corporation Integrated NetFlex-3/P
Compaq Computer Corporation Triflex Dual EIDE

YoZ
19.05.04, 20:59
kann hier denn keiner helfen?
die ausgabe von 'lspci' sieht so aus:



matrix:/home/yoz/software/irssi-0.8.9 # lspci
00:00.0 Host bridge: VIA Technologies, Inc. VT82C598 [Apollo MVP3] (rev 04)
00:01.0 PCI bridge: VIA Technologies, Inc. VT82C598/694x [Apollo MVP3/Pro133x AGP]
00:07.0 ISA bridge: VIA Technologies, Inc. VT82C686 [Apollo Super South] (rev 14)
00:07.1 IDE interface: VIA Technologies, Inc. Bus Master IDE (rev 06)
00:07.2 USB Controller: VIA Technologies, Inc. UHCI USB (rev 06)
00:07.4 Host bridge: VIA Technologies, Inc. VT82C686 [Apollo Super ACPI] (rev 10)
00:07.5 Multimedia audio controller: VIA Technologies, Inc. AC97 Audio Controller (rev 12)
00:0d.0 Ethernet controller: VIA Technologies, Inc.: Unknown device 3106 (rev 86)
01:00.0 VGA compatible controller: ATI Technologies Inc Rage 128 RF/SG AGP



aber im netz werden die pci devices so angezeigt:


PCI device 1106:8598
PCI device 1106:0686
PCI device 1106:0571
PCI device 1106:3038
PCI device 1106:3057
PCI device 1106:3058
PCI device 1106:3106
PCI device 1002:5246



Hat jemand eine idee warum und was ich da machen kann?

gruß, yoz