On Linux & Mac OS X, Python comes pre-installed. On Windows, we can install it from Windows store or from https://python.org website.
We can verify the Python version using the below command.
$ python --version
Python 3.11.6
We can use the pyftpdlib
library to create an FTP server. We can install the library using the below command.
$ python -m pip install pyftpdlib
[I 11:28:21] concurrency model: async
[I 11:28:21] masquerade (NAT) address: None
[I 11:28:21] passive ports: None
[I 11:28:21] >>> starting FTP server on :::2121, pid=99951 <<<
Now, we can start the FTP server using the below command.
$ python -m pyftpdlib
It will start the FTP server on port 2121. We can connect to the FTP server using the below command.
$ ftp localhost 2121
Top comments (0)