To run a job in background, you could directly append & to the end of your command, this is the same as pressing ctrl+z and running bg.
As your question deals about a long command, you should probably rather rely on nohup or screen, so that the encapsulated command continues running when you leave your terminal.
Using nohup
Example:
nohup my_long_command
# Leave your terminal (ctrl+D), my_long_command is still running
Remarks:
Using screen
- Install scren
sudo apt install screen
- Run a new screen session to run your long command:
# Open a "foo" screen
screen -S foo
my_long_command
# Detach this "foo" screen
screen -d foo
# Leave your terminal (ctrl+D), the screen is still running
- When you want to resume your screen:
# List running screens, "foo" will appear
screen -ls
# Reattach the "foo" screen
screen -r foo
- If you don't need the "foo" screen anymore:
# Close a screen
screen -XS foo quit
See also geeksforgeeks.org screen: screen command with example