Forum


Notice to all users

We are migrating towards a new forum system located at community.teamspeak.com, as such this forum will become read-only on January 29, 2020

Results 1 to 10 of 10
  1. #1
    Join Date
    May 2007
    Location
    Alabama
    Posts
    54

    File upload and their chmod

    Does the TS3 server set chmod to 700 to all uploaded files by default?

    In addition, how would I go about defaulting new files/folders to chmod 755?
    Last edited by Chris; November 27th, 2012 at 02:13 PM.

  2. #2
    Join Date
    April 2011
    Location
    Germany
    Posts
    1,266
    700 for all files?
    My teamspeak server assigns 644 to uploaded files and 700 to directorys created remotely using with the teamspeak client.

  3. #3
    Join Date
    May 2007
    Location
    Alabama
    Posts
    54
    Okay, I worded the above incorrectly, the permissions to files created are Okay.

    Yes the permissions to folders is 700, which then makes my file unreadable by the group apache I have assigned to the parent directories. Why would it be doing this? a better question, what can I do to make it apply 644 to the folders created?

  4. #4
    Join Date
    September 2012
    Posts
    6,079
    you cannot change the default permissions set to newly created folders / files.

    Also TeamSpeak files being owned by group apache? That sounds very wrong and potentially dangerous!

  5. #5
    Join Date
    May 2007
    Location
    Alabama
    Posts
    54
    My files folder is used by apache as an index to share file uploads. Worked great on windows when I run the server on windows.

    So why it the permission being set to 700? Is this a linux issue or TS issue causing this? Why is it that files are 644 when uploaded/created and folders are 700 when created by a client using the file transfer feature of TS3.

    For note. It is not owned by apache. It is owned by user teamspeak and group is apache.
    Last edited by squirrelof09; November 29th, 2012 at 06:37 AM.

  6. #6
    Join Date
    May 2007
    Location
    Alabama
    Posts
    54
    Any response for this?

  7. #7
    Join Date
    April 2011
    Location
    Germany
    Posts
    1,266
    You might write a cron job which checks every minute for new files oder directories and then change their access levels.

  8. #8
    Join Date
    May 2007
    Location
    Alabama
    Posts
    54
    I may consider this as I've been given this suggestion too. Wouldn't this lead to more disk usage and cpu usage especially if there are a lot of files already existing each time it did a check?

  9. #9
    Join Date
    April 2011
    Location
    Germany
    Posts
    1,266
    There would sure be some IO and CPU load to the host. It depends on the count of files and directories which needed to be processed.

    You might use the following little script:
    Code:
    # /bin/bash
    find /path/to/base/dir -type d -cmin 2 -print0 | xargs -r -0 chmod 750 
    find /path/to/base/dir -type f -cmin 2 -print0 | xargs -r -0 chmod 640
    The command "find" will be used to compile a list of all directories (-type d) below "/path/to/base/dir" which have changed in the last 2 min (-cmin 2). This list from "find" will be written to standard out and handed over by a pipe to xargs which will generate the need chmod 750 for directories.

    The second line will do the same for files... chmod is here 640.

    Just run this script by cron every x minutes... you might as well change the time in "cmin".
    Last edited by Barungar; December 1st, 2012 at 10:10 AM.

  10. #10
    Join Date
    May 2007
    Location
    Alabama
    Posts
    54
    Thank you for your response I will be looking into this sometime this week.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. I can upload any file
    By Colonel-Mitchell in forum General Questions
    Replies: 1
    Last Post: June 10th, 2013, 09:58 AM
  2. File upload 0k
    By voicehosting in forum Server Support
    Replies: 8
    Last Post: June 8th, 2012, 10:34 AM
  3. error when trying to upload a file
    By no1jester in forum Server Support
    Replies: 4
    Last Post: September 23rd, 2011, 04:45 AM
  4. File transfer chmod
    By Flowan in forum Linux / FreeBSD
    Replies: 1
    Last Post: September 23rd, 2010, 01:32 PM
  5. suggestion for File Upload
    By Dessy in forum Server Support
    Replies: 4
    Last Post: December 28th, 2009, 09:46 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •