Technology Insights

How To Not Be Prompted For Every File When Using Linux FTP mget Command

The other day I was attempting to use the Linux ftp command line application to obtain all of the files, sub directories, and files within the sub directories from an FTP site. The first issue I ran into was the issue of being prompted to confirm each and every file that is downloaded. Below I describe how to accomplish turning off the prompt and just to note I ended up using “wget” to download all of the files, sub directories, and files within the sub directories via FTP on the remote server.

Technology Insights

Count How Many Files Are In A Directory And All Sub Directories On A Linux Server

Counting files in Linux is fairly easy by simply listing the files using ls and then using the wc application. Both the ls application and the wc application are core Linux applications and should be installed by default on your server. One thing that I had forgotten how to do was how to count all files in a specific directory as well as all files in each sub directories. The second method I will display below is not 100% accurate because it will count sub directories twice however it is likely you just need a round about method to get an idea of how many files and sub directories you are working with. Below I describe first how to count all files and directories within a single directory and second how to count all the files, sub directories, and files within the sub directories via a Linux shell or command prompt.

Technology Insights

WordPress: Unable To Upload To The Media Library After Moving Servers

I recently moved a WordPress site from one location on a server to another location on the same server for a client. Everything seemed to work fine after following the directions in this article I had previously published. That article was specifically published for changing the domain that points to the WordPress site which could include simply changing the domain only or actually moving the site to a new server or new location on the same server and a new domain. If you are performing the second of those two options you may also need to update the “upload_path” depending on the configuration of the new server and if the paths are the same as they were on the initial server the WordPress site was installed on.

Technology Errors

RPMBuild Error: error: Installed (but unpackaged) file(s) found

It has been a long time since I built an RPM using a packages source so I had to brush up on my knowledge there before attempting to build an RPM package for CentOS today from curl’s source. In the process of building the curl RPM package for CentOS I received an error from rpmbuild stating that there was a rather large list of files that were unpackaged. Below I describe the rpmbuild unpackaged error along with a way to resolve the problem. I would love to hear any feedback people have on RPM building since it is not something I do on a regular basis my knowledge is limited.