mjpg_streamer, Octopi, Kubuntu Running my Flsun 3D Cube from a Kubuntu PC using Octopi, and trying to get my webcam to work with it. I've followed the instructions on Github for mjpg_streamer to the letter. Everything I've read says, "Sure! The Raspberry PI directions will work with Linux, you bet!" but they don't, at least, not for me, a beginning level Linux user.

I know that my webcam works with Kubuntu since I can load it and view it using VLC, but I've been unable to figure out how to get Octopi to read the stream from VLC (the documentation could use some improvement) or even confirm if the stream works.

Back to mjpg_streamer: when I issue the command 

export LD_LIBRARY_PATH=. ./mjpg_streamer -o "output_http.so -w ./www" -i "input_raspicam.so"


I get 

bash: export: 'mjpg_streamer': not a valid identifier
bash: export: '-o:' not a valid identifier
bash: export: 'output_http.so -w ./www': not a valid identifier
bash: export: '-i': not a valid identifier
bash: export: 'input_raspicam.so': not a valid identifier


I don't know what I don't know, and I don't know how to proceed. The goal is to view my webcam in Octopi/Octolapse on a Kubuntu PC. (Windows with Yawcam, no brainer; Linux, not so much.)
Going to post the answer here for posterity and for those, like me, trying to cope with Linux after making a career in Windows.

I'm running Kubuntu 18 because I didn't want to have to buy an operating system or install a bootleg copy of Windows. The most important thing for a Windows user to know is that the readme.md file is important. Think of it as a .chm file, or a series of linked help documents. What you want to know is THERE, not on the github page. 

Using the following command in the mjpg-streamer-experimental directory got me where I needed to go.

mjpg_streamer -i 'input_uvc.so -d /dev/video0 -r SVGA -f 30' -o 'output_http.so'


e.g. webcam, 800x600, 30fps to http (port 8080 is the default) The MD files break it down. I also found two web pages very useful: 

http://skillfulness.blogspot.com/2010/03/mjpg-streamer-documentation.html
https://wiki.ubuntuusers.de/MJPG-Streamer/

In OctoPrint the streaming setting is then:

http://127.0.0.1:8080/?action=stream


In my case, I use the network IP rather than local host so I can monitor the print from my upstairs PC. For snapshots: 

http://127.0.0.1:8080/?action=snapshot


I'll admit that Octolapse doesn't work for me yet because I'm still trying to work out ffmpeg, but that's another issue. EDIT: got that done, too. Useful command: 

whereis ffmpeg