In my case (x14 huoji), the command takes around 5 seconds. Maybe in a less powerful devices, it takes longer. When you typed "free" the second time, I can't see the prompt (when being root, it's the # character). Either you wait longer (give it a minute or two), or if unsure, do any harmless command and see if you get output, for example "ls" or "ls /dev". ls is simply a command to list the current directory or any other directory you pass as argument. Then, only when you get an output, run the free command again.
And another point, if instead of "free" you run "free -h", you will see that the big number of swap is actually... 6,5G of swap! So I would expect that disabling this takes some time.