Is it possible to transfer a feed to a different account?
There’s not a lot to go on there!
Self-hosted emoncms? emoncms.org?
Feed type? size?
Context or reasons behind the question?
Officially “No” but with more info there might be a work around.
Self hosted Emoncms. Phpfiwa and phptimeseries feeds. About 20 Mb each. There is one Phpfina as well.
So not so much “a feed”, how many feeds in total?
Why are you moving the feeds between users? Are you dividing the existing feeds between users or are you trying to “clean out” the admin account, looking for a fresh account?
Are both accounts live?
As I said there is no official way to do this and the more info you share the more likely we are to find a solution.
The only thing that ties a feed to a user is the userid field in the mysql table, although not a recommended way of doing things, you might be able to just edit the userid of the feeds you wish to move. BUT this can be messy due to caching and redis etc. At the very least I would recommend stopping the server service, making the changes via phpmyadmin or the mysql commandline and flush redis before restarting the server. If this is not an emonpi/emonbase self-hosted emoncms with redis running, I think there is also a redis backup file that should be deleted too (this is not used on the RO OS based installs).
But maybe there’s a better way if you tell us what it is you are trying to achieve.
Yeah, good points. I currently have a a few different accounts. I used to have a few different emonbase’s for the different feeds but now I want to combine them under one emonPi and get rid of some of the feeds, but keep the data coming for some in one account.
What would happen if I just swapped the userid of the feed? Are the feeds stored in different locations depending on userid? Would they be found?
All the phpfina, phpfiwa and phptimeseries feeds for all users are in a folder of the same name in /home/pi/data.
As I previously said the userid is the only real link between a user and the users feeds. But it can be messy to play with as there you may be battling against buffered-writes, caching, indexing and Redis when using a backdoor method to change.
Another method might be to create new empty feeds for the new user and then stop the system updating and then duplicate the original feed files and rename them to replace the new feeds created for the new user. Again you are using a back door method so the “system” is working against you.
I like that last option. Copying the data into a new feed. Will that work? It’s worth a try. Thanks.