Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. getting quota (space) for an logged-in user in FTP

getting quota (space) for an logged-in user in FTP

Scheduled Pinned Locked Moved C / C++ / MFC
helpsysadmin
4 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    harinat
    wrote on last edited by
    #1

    Hello Guys, How ru doing, I need some help in FTP, first i will clearly explain u the situation..... i have one one FTP user login, i have logged into the FTP server with that login, now by code i need to know how much space like .... The total space allocated for the user, the space occupied by the user, and the remaining space. currently i have one solution...but its not working fine...i.e i can execute a FTP command through code like "ls", doing this will return a string to me containing the result(text string) for the executed command. the problem here is this is not working all the time....if the data commection is lost it just hangs offff and many other problems are there. guys plz help me out of this problem....waiting for the solution

    T 1 Reply Last reply
    0
    • H harinat

      Hello Guys, How ru doing, I need some help in FTP, first i will clearly explain u the situation..... i have one one FTP user login, i have logged into the FTP server with that login, now by code i need to know how much space like .... The total space allocated for the user, the space occupied by the user, and the remaining space. currently i have one solution...but its not working fine...i.e i can execute a FTP command through code like "ls", doing this will return a string to me containing the result(text string) for the executed command. the problem here is this is not working all the time....if the data commection is lost it just hangs offff and many other problems are there. guys plz help me out of this problem....waiting for the solution

      T Offline
      T Offline
      Ted Ferenc
      wrote on last edited by
      #2

      in UNI*/perl $dir = "/myserver/mydir"; $aa=qx(du -s -k -m $dir); print " size of website in MB $aa "; in FTP I think your only solution is to manually recurse through all the subdirectories geting the size of each file, if you are using the MFC CFtpFileFind is one solution


      "Laughing at our mistakes can lengthen our own life. Laughing at someone else's can shorten it." - Cullen Hightower

      H 1 Reply Last reply
      0
      • T Ted Ferenc

        in UNI*/perl $dir = "/myserver/mydir"; $aa=qx(du -s -k -m $dir); print " size of website in MB $aa "; in FTP I think your only solution is to manually recurse through all the subdirectories geting the size of each file, if you are using the MFC CFtpFileFind is one solution


        "Laughing at our mistakes can lengthen our own life. Laughing at someone else's can shorten it." - Cullen Hightower

        H Offline
        H Offline
        harinat
        wrote on last edited by
        #3

        Ted...thanks for ur reply man... Actually the Server which iam going to connect is Windows wunning Windows Media Server as u said iam able to get the size of the files in the server...but i need one more thing...i.e the maximum space allocated for the user...i.e in my application i upload some as per the user request...when uploading the file, i should the left out empty space for the user..if its less then i have stop the upload ...this is the scenario....got it fed....can u help me out of this solution

        T 1 Reply Last reply
        0
        • H harinat

          Ted...thanks for ur reply man... Actually the Server which iam going to connect is Windows wunning Windows Media Server as u said iam able to get the size of the files in the server...but i need one more thing...i.e the maximum space allocated for the user...i.e in my application i upload some as per the user request...when uploading the file, i should the left out empty space for the user..if its less then i have stop the upload ...this is the scenario....got it fed....can u help me out of this solution

          T Offline
          T Offline
          Ted Ferenc
          wrote on last edited by
          #4

          Sorry can't help you there.


          "Laughing at our mistakes can lengthen our own life. Laughing at someone else's can shorten it." - Cullen Hightower

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups