{"id":310,"date":"2014-06-12T01:01:10","date_gmt":"2014-06-12T01:01:10","guid":{"rendered":"https:\/\/qbytes.cloud\/?p=310"},"modified":"2014-06-12T01:01:10","modified_gmt":"2014-06-12T01:01:10","slug":"find-number-of-files-in-a-directory","status":"publish","type":"post","link":"https:\/\/www.qbytes.cloud\/index.php\/2014\/06\/12\/find-number-of-files-in-a-directory\/","title":{"rendered":"public_html directory not showing in ftp"},"content":{"rendered":"<p>A user could not show the public_html directory on a cpanel server. Run the following to see how many files are listed in the directory.<\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\ncd \/home\/username\nls|wc -l\n10050\n\n<\/pre>\n<p>This folder has 10500 files. The settings for ftp do not allow a full directory listing. We removed the files that were not needed and ftp worked.<\/p>\n<p>Also this is a setting in \/etc\/pure-ftpd.conf<\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\nnano \/etc\/pure-ftpd.conf\n# &#039;ls&#039; recursion limits. The first argument is the maximum number of\n# files to be displayed. The second one is the max subdirectories depth\n\nLimitRecursion 10000 8\n\n<\/pre>\n<p>To change this &#8211; change the line amount in the first number and restart ftp<\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\nLimitRecursion 11000 8\nservice pure-ftpd restart\n<\/pre>\n<p>To change the ftp maximum number of files on plesk.<\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\nnano \/etc\/proftpd.conf\nListOptions -a maxfiles 2000 maxdepth 3\n\n<\/pre>\n<p>Restart xinetd<\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\n service xinetd restart\n\n<\/pre>\n<p>This configures the -a option by default, and limits the maximum files in the generated listing to 2000. If the client uses the -R option, proftpd will not recurse into directories more than 3 levels deep when generating the listing. <\/p>\n","protected":false},"excerpt":{"rendered":"<p>A user could not show the public_html directory on a cpanel server. Run the following to see how many files are listed in the directory. cd \/home\/username ls|wc -l 10050 This folder has 10500 files. The settings for ftp do not allow a full directory listing. We removed the files that were not needed and &#8230; <a title=\"public_html directory not showing in ftp\" class=\"read-more\" href=\"https:\/\/www.qbytes.cloud\/index.php\/2014\/06\/12\/find-number-of-files-in-a-directory\/\" aria-label=\"Read more about public_html directory not showing in ftp\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[16,20,42,86,89],"tags":[],"class_list":["post-310","post","type-post","status-publish","format-standard","hentry","category-cli","category-cpanel","category-ftp","category-plesk","category-proftpd"],"_links":{"self":[{"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/posts\/310","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/comments?post=310"}],"version-history":[{"count":0,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/posts\/310\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/media?parent=310"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/categories?post=310"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/tags?post=310"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}