Bug 21497 - univention-system-info löscht vorhandenes Verzeichnis unter /tmp
univention-system-info löscht vorhandenes Verzeichnis unter /tmp
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: Sysinfo
UCS 2.4
Other Linux
: P5 normal (vote)
: UCS 3.1
Assigned To: Felix Botner
Lukas Walter
: interim-3
Depends on:
Blocks: 15223
  Show dependency treegraph
 
Reported: 2011-02-07 17:50 CET by Janek Walkenhorst
Modified: 2012-12-12 21:07 CET (History)
2 users (show)

See Also:
What kind of report is it?: ---
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional):
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Janek Walkenhorst univentionstaff 2011-02-07 17:50:37 CET
Wenn unter /tmp bereits ein Verzeichnis mit der UUID existiert, löscht u-s-i den Inhalt.
Außerdem funktionieren in dem Fall die Parameter -m und -t nicht korrekt.

/tmp # ll
  insgesamt 0
/tmp # univention-system-info -u -m x -t x
  [snip]
/tmp # ll
   insgesamt 0
/tmp # tar -xf /var/www/univention-management-console/system-info/564D09ED-53A4-C7E8-626A-D932140791FF.tar.gz 
/tmp # ll
  insgesamt 4,1k
  drwx------ 3 root root 4,1k  7. Feb 17:45 564D09ED-53A4-C7E8-626A-D932140791FF/
/tmp # cat 564D09ED-53A4-C7E8-626A-D932140791FF/info 
   Manufacturer: x
   Model       : x
   Comment     : 
   Ticket No   : 
/tmp # touch 564D09ED-53A4-C7E8-626A-D932140791FF/My.Important.Data
/tmp # univention-system-info -u -m y -t y
  [snip]
/tmp # ll
  insgesamt 0
(Daten sind weg)
/tmp # tar -xf /var/www/univention-management-console/system-info/564D09ED-53A4-C7E8-626A-D932140791FF.tar.gz 
/tmp # ll
  insgesamt 4,1k
  drwx------ 4 root root 4,1k  7. Feb 17:46 564D09ED-53A4-C7E8-626A-D932140791FF/
/tmp # cat 564D09ED-53A4-C7E8-626A-D932140791FF/info 
   Manufacturer: x
   Model       : x
   Comment     : 
   Ticket No   : 
(Immer noch "x")
Comment 1 Stefan Gohmann univentionstaff 2012-07-17 17:09:41 CEST
UCS 3.1 will be the next release.
Comment 2 Felix Botner univentionstaff 2012-10-31 12:49:56 CET
Vorhandene Archive bzw. UUID Verzeichnisse werden nun nach .bak.$(date +%s) verschoben.
Comment 3 Lukas Walter univentionstaff 2012-11-09 12:56:29 CET
(In reply to comment #2)
> Vorhandene Archive bzw. UUID Verzeichnisse werden nun nach .bak.$(date +%s)
> verschoben.

Verhalten wie beschrieben.

================================================================================
root@mas28:/tmp# univention-system-info -u -m x -t x
Temp: /tmp/tmp.Ra0a6sp2Mk
archive:9FC39174-DC4F-20E8-2D69-914A626F6DCC.tar.gz
cpu:QEMU Virtual CPU version 0.14.1
num_cpu:1
mem:1034116 kB
net_dev:Red Hat, Inc Virtio network device
gfx_dev:Cirrus Logic GD 5446
root@mas28:/tmp# tar xf /var/www/univention-management-console/system-info/9FC39174-DC4F-20E8-2D69-914A626F6DCC.tar.gz
(reverse-i-search)`ech': ^Cho lol > rofl
root@mas28:/tmp# echo important > 9FC39174-DC4F-20E8-2D69-914A626F6DCC/important_data
(reverse-i-search)`-y': apt-get update; apt-get dist-upgrade -y --force^Ces
root@mas28:/tmp# univention-system-info -u -m y -t y
Temp: /tmp/tmp.8nQWSgH7wu
archive:9FC39174-DC4F-20E8-2D69-914A626F6DCC.tar.gz
cpu:QEMU Virtual CPU version 0.14.1
num_cpu:1
mem:1034116 kB
net_dev:Red Hat, Inc Virtio network device
gfx_dev:Cirrus Logic GD 5446
root@mas28:/tmp# cat 9FC39174-DC4F-20E8-2D69-914A626F6DCC.bak.1351688044/important_data 
important
================================================================================

Es gibt einen Typo im Changelog: \item \ucsName{univention-system-info} has been modified to backup
existing archives before creating the sysinfo archiv"
                                                    ^ e

Daher noch mal REOPENED.
Comment 4 Felix Botner univentionstaff 2012-11-09 14:43:08 CET
Changelog angepasst.
Comment 5 Lukas Walter univentionstaff 2012-11-09 15:01:37 CET
(In reply to comment #4)
> Changelog angepasst.

Verified.
Comment 6 Stefan Gohmann univentionstaff 2012-12-12 21:07:57 CET
UCS 3.1-0 has been released: 
 http://forum.univention.de/viewtopic.php?f=54&t=2125

If this error occurs again, please use "Clone This Bug".