Jump to content

Mk4 - Scp Troubles


hfam
 Share

Recommended Posts

Hopefully this is an easy one.

I've got 2 hornet-ub's with OpenWRT already loaded on them.

Trying to put the "upgrade.bin" file on them to upgrade them to an MK4.

I'm connected with a serial cable and an eth cable in PoE/LAN.

I've connected to the serial port with PuTTY, set the password, and started dropbear per the instructions in another thread.

I'm on Win7, so I grabbed WinSCP (both .exe and .com).

I put winscp.com and the upgrade.bin in the same directory.

I open a command prompt, go to the "scp" directory, and run "winscp 192.168.2.1"

It connects, and prompts me for a username, which I respond "root"

It prompts me for a password, which I provide the one I created: "pineapplesareyummy"

It then indicates "Authenticated"

The next thing that happens is I get:

"Connection has been unexpectedly closed. Server sent command exit status 127. Cannnot initialize SFTP protocol. Is the host running a SFTP server?"

and I'm stuck.

I've followed the steps outlined in the flashing thread to a "T" (at least the relevant parts...I didn't need to put OpenWRT on these as it's already there, so I started from that point

Once OpenWRT finishes booting press ENTER to active the console. Issue passwd and set a root password. Next start the ssh service /etc/init.d/dropbear start

Move the Ethernet cable from the WAN/LAN port to the PoE LAN port.

From the PC ping 192.168.2.1 to verify a connection. From here you'll need to SCP over the latest MK4 update from http://wifipineapple.com/mk4/firmware

SCP the latest firmware .bin file to the Pineapple's /tmp/ directory (windows: http://winscp.net/eng/index.php linux: you already have scp)

scp firmware.bin root@192.168.2.1:/tmp/

Once the firmware has been copied to the pineapple's /tmp/ directory you're ready to update the factory firmware to the latest version of the Jasager suite. On the pineapple issue:

sysupgrade -n -v /tmp/firmware.bin

The upgrade process takes 2-3 minutes. When complete the Pineapple will reboot and all will be happy again in the land of the pineapple. Continue with normal usage (ie: change your PC's ethernet interface back to DHCP or static it to 172.16.42.42)

Darren? seb? Anyone?

I don't see where I'm supposed to turn on a SFTP server on the board, but it appears that scp is looking for that.

I also ran the GUI version of Winscp, and told it to "allow fallback to scp" (it defaults to SFTP), and I get the same results.

Any help would be GREATLY appreciated! Thanks guys!

Link to comment
Share on other sites

Dropbear doesn't support sftp in what I just read on http://linuxexplore.wordpress.com/how-tos/sftp-secure-file-transfer-protocol-with-dropbear/

scp doesn't work the way you're using it I think. You don't "scp into a box", like ssh. Instead, you securely copy files from your host computer to the client.

For instance:

scp Myl33tfilez root@172.16.42.1:/usb

Enter password for root@172.16.42.1: pineapplesareyummy

Copying some badass l33t shit over to the pineapple.......DONE

I've never used scp in a command line on windows - I didn't even know you could without a gui like winscp lol...Fire up the gui winscp and use scp instead of sftp with fallback. I wish I could be more concrete in my advice, but my serial cable is still on its way!

telot

Link to comment
Share on other sites

You can also install openssh sftp server, which will work alongside dropbear.

The package is called: openssh-sftp-server. Installing this should allow you to use winscp.

You can't install it on usb storage though, tried it before and it only worked when installed on internal memory.

Link to comment
Share on other sites

I love you guys soooo much!!! :) :)

Taking my wife out for our wedding anniversary dinner shortly, so I'm not sure if I'll get a chance to try all your fine suggestions tonight (if I'm lucky, I won't have time until tomorrow...know what i mean? ;) ;) ;) )

I'll definitely be back to weigh in with the results though, as soon as I'm not "anniversarying", thanks again for all the quick responses fellas!

Link to comment
Share on other sites

I love you guys soooo much!!! :) :)

Taking my wife out for our wedding anniversary dinner shortly, so I'm not sure if I'll get a chance to try all your fine suggestions tonight (if I'm lucky, I won't have time until tomorrow...know what i mean? ;) ;) ;) )

I'll definitely be back to weigh in with the results though, as soon as I'm not "anniversarying", thanks again for all the quick responses fellas!

Swoot! Swoot! Bring the pineapple with! Nothing turns on a girl like a pineapple...right?

Enjoy the night man - my one year is coming up in April :::aww yeah face:::

telot

Link to comment
Share on other sites

Thanks for the well wishes Telot, and congrats on your upcoming 1 year...I had an awesome night here!

So, I started with the simplest explanation first: settings, and of course, Occam's Razor wins again...and so does seb. :)

Indeed, it was forcing it to SCP in WinSCP via the pulldown menu that did the trick! w00tz! (note to others, WinSCP does throw a few goofy "group" errors after connecting, but just "OK" past them to get the interface, which is really nice BTW)

Thanks again for the assist fellas, and I guess I'll be the first outside the devteam to confirm here and now that the flashing method outlined in another thread works perfectly!

It's really REALLY nice that we don't have to use the TTY serial to apply updates (the new method is SOOO much cleaner than the MK3!), but it's also really nice to know that if for whatever reason the code bricks, that having the cable, the system firmware, and the latest MK4 updates at hand, we can bring 'em back from the grave fairly easily.

For the record, the setup I used was:

- TrendNET TU-S9 USB to Serial(9 pin) - I had this around for many other applications I need it for

- Alfa Serial(9pin) to TTL - Was gifted this board/cable for helpin' a brother out

- Serial F/F gender changer - bought this via Amazon to connect the two together for a few bucks

aahahah! I know...but it's what I had to work with. It actually made a really nice, stable piece of gear, but a nice clean USB to TTL cable would be best. :)

It'll be interesting to see what Darren determines is best and puts in the hakshop.

Thanks again for all the help guys.

Edited by hfam
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...