However the last part ">/dev/null 2>&1&" I'm not sure what it does
The final '&' is required. It runs the command in background (disconnected from the terminal).
">/dev/null 2>&1" redirects any output to the null device (just discards it), else "nohup" would write it to nohup.out
There are always two output streams under unix, standard output and error, ">/dev/null" redirects the standard output while "2>&1" tells it to put the error stream (2) in the same place as the standard output stream (1).
Finally the "nohup" just traps the "hangup" signal, so the program running in background does not quit when you log off (hangup being terminology from the old days of dialup terminal sessions).
Unix is fun