SFTP ",u" (comma and u letter) option when downloading from HP-UX server - sftp

I was downloading a file from one HP-UX server, to an Red Hat Linux server. The file is around 6 or 7 GB.
Using sftp, I tried getting the file, but no matter how many times I try, it always reaches 80% and just exits. No error code, no error description, nothing.
Another team was copying the same file, so they shared their script, and apparently, in the get command, they add ",u":
get XYZ,u XYZ
I tried doing that and to my surprise it worked. However I cannot find that option anywhere else online, and I sort of want to know what is it.

It must be some server-specific hack.
It's not an sftp option. From the local sftp client perspective, you are downloading a file with a name XYZ,u.

Related

R Studio incredibly slow only after I connect to my work VPN?

I have R Studio on Windows. It works fine before I connect to the internet through my VPN. After I connect commands start to hang, autocomplete can take forever, and simple operations like 4 + 4 can take one minute or more.
I have a feeling the studio is making connections under the hood. I would like to disable all of these connections no matter what.
I have experienced the same thing - I am assuming your actual work is on a file server and not local. I found the culprit in my case to not be RStudio directly, but rather the RStudio project file. RStudio will create a generally small, hidden folder in the directory named .Rproj.user with some settings. This, living on the file server, caused constant read/writes through my VPN connection.
I unfortunately had to either (a) move projects off the file server into a local copy (not bad since I can use a company GitLab), or (b) delete the .Rproj and .Rproj.user folders from the project directory on the server and use here::here() or something like that as a work around in my workflow.
As another possibility, I have seen installations of R itself done onto a personal server drive instead of locally. This has been done to avoid needing administrator privileges to install. This is not a great idea and can also result in extremely slow performance through a VPN connection. You can check to see where R is installed as well. Sounds like this is not the problem though based on what you described.
Maybe it is something else, but this is what I found last week for me based on a very similar experience.

RStudio error message - the device does not recognize the command

I am repeatedly getting the error message:
Error Save File: ' The device does not recognize the command' popping up over and over (every 15 seconds) - even when I don't click save or when I do click save.
I also can't load a R file that is in my folder - I have to open it up in notepad and copy it paste it to even see it.
Can someone let me know how to fix this? I have the latest version of Rstudio installed.
This happens when the drive memory runs out of space. As a quick fix measure, try copying all the code to an another R script file/ notepad and you might save it luckily. Long term solution would be to clear the cache and upgrade your hard drive..
This can also happen if you are reading from a file that is open in another program in some cases. Generally speaking R has no issues reading in files that are open / read only (i.e. import a CSV file) if that file is in use by another process. However, there are some cases where the read-only restriction from a locked file being imported causes the
Error Save File: ' The device does not recognize the command'
message to persist even if you are not trying to to read from or write to the locked file.
As a specific example, if you are using openxlsx to import an xlsx file that you are also viewing in excel, after reading the xlsx file in, you will get the error whenever you make changes to your R script and stop for more than a few seconds, or when you try to save the R script, even though it is not touching the xlsx file. However, if you close R Studio and re-open your script, you will notice that the issue will not appear until you try to read the xlsx file in again.
Met error "The device does not recognise the command" today. Not due to disc space but due to an r script that was somehow no good, even though file extension OK. After a very frustrating time when I couldn't copy to a fresh R script or shut down the project, saved content of troublesome r script to another older r script, deleted it and all OK - e.g. could now open up another new script that saved with no problems.

How to clear searchable history database in RStudio

In addition to the .Rhistory file,
RStudio maintains a database of all commands which you have ever entered into the Console. You can browse and search this database using the History pane. (source)
This one appears to still be searchable even when .Rhistory has been deleted.
How can I empty it? Cleaning it up might be necessary after, for example, installing from a private repo using a password, when I know other users have access to the computer. For example, I was a bit anxious seeing this popping up, after entering pass into the search field... (ノ゚0゚)ノ~
Thanks to Phann's hint, I found:
Deleting history_database seems to do the job. An empty database file is automatically recreated when starting RStudio again (tested on MacOS and Linux). The folder where to find history_database depends on your os and is described for the more general case here.
MacOS and Linux
~/.rstudio-desktop
Windows Vista, 7 and 8
%localappdata%\RStudio-Desktop # (i.e. Phann's path, I guess)
Windows XP
%USERPROFILE%\Local Settings\Application Data\RStudio-Desktop
Linux RStudio-Server
~/.rstudio
On my Win7 system, I found the file history_database within C:/Users/../AppData/Local/RStudio-Desktop. It has a unix-like time stamp per line followed by a command.
I would guess that if you empty this file, the history is cleared. But I haven't tried the solution yet, so better make a copy of the file to be on the save side.
The file should be in a similar folder in Win10.

Plot() error when using REngine.Rserve

I'm now work on a project which wants to use org.rosuda.REngine.Rserve to use facilities of R by C#. I have a particular problem that when I run the following code in C# client side:
c.eval("pdf(file=\"plots.pdf\", width=11, height=8.5)");
c.eval("plot(1,2)");
An error occour which said
Error in plot.new():cannot open file '', reason No such file or directory
But I checked that the file "plots.pdf" has already been created successfully by "pdf.." function. In R semantics, the successive plot() will output figure to the active device opened by the "pdf(...)" function, i.e. "plots.pdf" this time. But I'm very confused that why the error indicated that the file is ''.
I use R-2.15.0 and Rserve-1.7.0 in linux server side.
I'm eager to see your response.
Thanks a lot.
Try this code :-
c.eval("dev.off()")
A folder named (null).1001.1001
Related answer at
Cannot open file '', reason No such file or directory
suggests using file.path as a alternative to paste for creating filenames with platform-independent path separators.
Comments suggest dev.off(). I had better luck with graphics.off(). The difference is that dev.close() closes the current device, graphics.off() closes all open devices.
But my solution turned out to be
https://askubuntu.com/questions/721485/what-is-folder-null-1001-1001
I found a mysterious folder named (null).1001.1001 (Rserve is running as uid 1001, gid 1001 on Linux). I create this folder at the start of my session and I'm good to go. The presence of this folder seems to help in my case, but I don't know (yet!) what that folder is.

Can't Write Configuration File

I have been unsuccessful in getting Aptana 3.0.8 to start. I keep getting the error
The configuration area at 'C:\Users\Devon\.eclipse\com.aptana.rcp.product_3.0.8.201201201658_68819209\configuration' is not writable. Please choose a writable location using the '-configuration' command line option.
I have used the -configuration command within the target area of my shortcut to point to two different locations at two different times.
First I made a folder in the root of my drive and made sure that it was writable, but still got the same error, except it would say that the folder I specified was not writable instead of listing the folder in the above error.
I also tried to point it to write to a mapped network drive via my server and it still gave me the same error.
I have read other posts on this site and none of the resolutions solved my issue. I also went into my local appdata folder and changed the path of the default workspace location within the config.ini folder and changed it to a directory that does not have spaces in its name in hopes that would resolve the issue.
I really needed to work on my business website and thus have installed Aptana 2 in the mean time because that seems to be working without any issues. However I would really like to be able to get Aptana 3 working.
I am running Windows 7 Pro x64
Thanks in advance for any help provided here

Resources