[Home]

Summary:ASTERISK-12364: Sound installer extracts with originating user/group ids.
Reporter:Mark Hulber (hulber)Labels:
Date Opened:2008-07-11 05:07:09Date Closed:2008-07-11 10:36:31
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Sounds
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:
Description:The sound installer is extracting, using tar with the user and group id of the original machine instead of the new target.  

****** ADDITIONAL INFORMATION ******

I was curious so I took a look at my sounds directory.  Most of the files are 644 except the g729 which are 444.  I also noticed that the ownerid/groupid are a non-existent 1000/1000.  I take it that the sound installer uses something like "tar" with the option to keep the original owner and groupid which it shouldn't be doing.  If appears that tar should use at least the option "-o" when doing the extraction to /var/lib/asterisk/sounds.

-rw-r--r--  1 1000 1000    6985 Dec  5  2007 zip-code.alaw
-rw-r--r--  1 1000 1000    6985 Dec  5  2007 zip-code.g722
-r--r--r--  1 1000 1000     870 Dec  5  2007 zip-code.g729
-rw-r--r--  1 1000 1000    1452 Dec  5  2007 zip-code.gsm
-rw-r--r--  1 1000 1000    6985 Dec  5  2007 zip-code.ulaw
-rw-r--r--  1 1000 1000   14014 Dec  5  2007 zip-code.wav

from asterisk/sounds/Makefile:

Makefile:       @PACKAGE=$(subst $(SOUNDS_DIR)/.asterisk,asterisk,$@).tar.gz; \
Makefile:       (cd $(SOUNDS_DIR); cat $(PWD)/$${PACKAGE} | gzip -d | tar xf -) && \
Makefile:       @PACKAGE=$(subst $(SOUNDS_DIR)/.asterisk,asterisk,$@).tar.gz; \
Makefile:       (cd $(SOUNDS_DIR)/es; cat $(PWD)/$${PACKAGE} | gzip -d | tar xf -) && \
Makefile:       @PACKAGE=$(subst $(SOUNDS_DIR)/.asterisk,asterisk,$@).tar.gz; \
Makefile:       (cd $(SOUNDS_DIR)/fr; cat $(PWD)/$${PACKAGE} | gzip -d | tar xf -) && \
Makefile:       @PACKAGE=$(subst $(SOUNDS_DIR)/.asterisk,asterisk,$@).tar.gz; \
Makefile:       (cd $(SOUNDS_DIR); cat $(PWD)/$${PACKAGE} | gzip -d | tar xf -) && \
Makefile:       @PACKAGE=$(subst $(SOUNDS_DIR)/.asterisk,asterisk,$@).tar.gz; \
Makefile:       (cd $(SOUNDS_DIR)/es; cat $(PWD)/$${PACKAGE} | gzip -d | tar xf -) && \
Makefile:       @PACKAGE=$(subst $(SOUNDS_DIR)/.asterisk,asterisk,$@).tar.gz; \
Makefile:       (cd $(SOUNDS_DIR)/fr; cat $(PWD)/$${PACKAGE} | gzip -d | tar xf -) && \
Makefile:       @PACKAGE=$(subst $(MOH_DIR)/.asterisk,asterisk,$@).tar.gz; \
Makefile:       (cd $(MOH_DIR); cat $(PWD)/$${PACKAGE} | gzip -d | tar xf -) && \


      -o, --no-same-owner
             do not attempt to restore ownership when extracting; -o exhibits this behavior when  extracting  an
             archive
Comments:By: Kevin P. Fleming (kpfleming) 2008-07-11 10:36:24

This has been fixed in revision 129907 of branches/1.4, and merged to trunk and 1.6.0.