Zomg help!

Results 1 to 19 of 19
  1. #1
    Member Allisandre is offline
    MemberRank
    Dec 2011 Join Date
    MichiganLocation
    68Posts

    Zomg help!

    OK, so here's the skinny...

    I had my server all setup and running. Friends were playing, all was well. I was working on making some of the folders shared on the network so that I could make edits using the software that was created for Windows.

    Part of my instructions said that to make it easier for eveyone on the network to work with the files, I should run "chmod -R 0777 /folder". I figure I'm everyone atm, so this isn't a bad idea.

    boy I was wrong.

    So through the lack of good keyboarding skills, I missed typing the folder when I did this. I ended up typing "chmod -R /" or something like that. Server kept on chugging for a while, I could see it from the windows network to work with files, all was well.

    So I thought.

    Then the server shut down overnight. brought it back up in the morning, and could not log in as root anymore. Through some searching, I realized what a horrendous FUBAR I made of it, and have been trying to restore the system.

    since I did not want to lose everyone's accounts and characters, I copied the PWServer folder off onto a USB Drive.
    After re-installing Ubuntu Server and the server-root, I then printed a list of the permissions within the /PWSeerver/gamedbd folder from my clean install, copied the same folders off the USB backup to a temp directory, fixed the permissions, and then copied the fixed backups into the live server directory.

    Fired up the server, logged into pwAdmin, and discovered that everything is still missing. >.<

    so, if that's not where the accounts and characters are stored, where are they?


  2. #2
    Proficient Member Souris is offline
    MemberRank
    Feb 2009 Join Date
    167Posts

    Re: Zomg help!

    characters are stored in the "wdata" (not sure of the name) folder which is a subfolder of the gamedb by default. You also need the info in subfolder of uniquename.

    A good idea is to move these two somewhere else, as the pw folder get messed with quite often. You can do so by editing the config file of gamedb and uniquename.

    Edit: example from my setup with gamedb
    Code:
    [storagewdb]
    homedir                  =   /srv/disk1/
    datadir                  =   dbdata/gamedbd
    logdir                   =   /home/pw/log/gamedbd
    backupdir                =   backup/gamedbd
    With this the data files are in: /srv/disk1/dbdata/gamedbd/ . Note that backup does not seem to work at all and that the part under [storage] in the config is useless.
    Last edited by Souris; 13-12-11 at 01:24 PM.

  3. #3
    3D Illusionist Drakaer is offline
    MemberRank
    Apr 2010 Join Date
    In My Own WorldLocation
    946Posts

    Re: Zomg help!

    Characters are stored in the a berkley database you can look in one of the config files to find the paths. Its could be /dbf/ or dbhome of something similar. There a posts about that.

    Accounts are stored in the mysql database.

  4. #4
    Member Allisandre is offline
    MemberRank
    Dec 2011 Join Date
    MichiganLocation
    68Posts

    Re: Zomg help!

    ok, I was hoping this would be easier.I kind of understand what you guys are talking about, but am totally clueless on the locations. I used 343's release and it's pretty vanilla for the file/directory layout.

    The only folder that i managed to get backed up was the /PWServer folder and it's subdirectories/files. It's starting to sound like I'm totally screwed, even if I try using the backup that I made from pwAdmin a few days ago. The only directory you mentioned I am familiar with is /gamedebd, but Souris has listed it in 3 different locations, none of which I know.

    I've got about 2 hours to get this fixed or a lot of people are going to be really pissed at me, and it looks like I've lost my paddle.

  5. #5
    Account Upgraded | Title Enabled! norman1234 is offline
    MemberRank
    May 2009 Join Date
    303Posts

    Re: Zomg help!

    Lol that happens to the best of us but its easier to change permissons from winscp but just tell everyone to remake the accounts and its trial and error
    Posted via Mobile Device

  6. #6
    Member Allisandre is offline
    MemberRank
    Dec 2011 Join Date
    MichiganLocation
    68Posts

    Re: Zomg help!

    yes, so I broke down, went and changed the permissions on all the files in my backup of PWServer, copied it back in, and no users. >.<

    So, everyone has to start over. I'm tempted to believe that the character data is there somewhere, but have no clue about how I would go about retrieving it and applying it back to their accounts when they re-create them.

  7. #7
    Proficient Member Souris is offline
    MemberRank
    Feb 2009 Join Date
    167Posts

    Re: Zomg help!

    Copy the content of gamedbd and uniquenamed config (the storagewdb part) and we'll be able to tell you where your data are.

  8. #8
    Omega 343 is offline
    MemberRank
    Oct 2009 Join Date
    Ancient DGN CTYLocation
    5,514Posts

    Re: Zomg help!

    The players and their accounts are totally separated. So, if you were able to back up the actual DB (which are all the files in /PWServer/gamedbd/dbhomewdb/dbdata/) then all the characters and whatnot are still there. However, if you did not back up MySQL DB, yes, the user accounts will be gone. However, when and once new accounts a (re)created the characters that were there previously (and in /PWServer/gamedbd/dbhomewdb/dbdata/) will still be there with the same character number... IE... the very first account you create is going to be user #32. Once you create user 32 again (that happens in MySQL) you will have your character 32 back it it's exact state that it was last saved as in /PWServer/gamedbd/dbhomewdb/dbdata... Bearing that in mind, if accounts aren't created in the same exact order they were before people aren't going to have the same characters (some people will wind up with other peoples accounts basically)...

    This is why it is very important to make back-ups of both:

    MySQL
    &
    /PWServer/gamedbd/dbhomewdb/dbdata

    Add:

    Luckily if you're just running a little server for you and some friends to play on it shouldn't be too hard to figure it out and straighten out accounts to characters. Just have them create accounts, ask them their characters name. Then edit their account number in MySQL to match the character names they give you (and you retrieve through pwAdmin)

  9. #9
    Member Allisandre is offline
    MemberRank
    Dec 2011 Join Date
    MichiganLocation
    68Posts

    Re: Zomg help!

    oh damn. I got so exited after reading your post 343.

    Here's a rundown of what I've done so far...
    1. scrwed up the permissions and hosed the server.
    2. Backed up the folder "/PWServer" and all subfolders/files. (I tried to get more, but I had a lot of issues with copying those.)
    3. Wiped the system and re-installed clean.
    4. Corrected the permission values on all the files from my PWServer backup to match the permissions of the files on the clean install.
    5. copied the backup files over the top of the clean install.
    6. fired up the server.
    7. started an account (hoping to see my first GM toon)
    8. cried because it wasn't there after refreshing the database.

  10. #10
    Omega 343 is offline
    MemberRank
    Oct 2009 Join Date
    Ancient DGN CTYLocation
    5,514Posts

    Re: Zomg help!

    hmm...

  11. #11
    Member Allisandre is offline
    MemberRank
    Dec 2011 Join Date
    MichiganLocation
    68Posts

    Re: Zomg help!

    Here's my gamedb and uniquenamed I think...
    the only *.conf files in there are gamesys.conf, is that what you meant?

    gamedb
    Code:
    [GameDBServer]
    zoneid=1
    aid=1
    type			=	tcp
    port			=	29400
    address			=	127.0.0.1
    so_sndbuf		=	16384
    so_rcvbuf		=	16384
    ibuffermax		=	1048576
    obuffermax		=	1048576
    tcp_nodelay		=	0
    listen_backlog	=	10
    accumulate		=	16777216
    
    [LogclientClient]
    type			=	udp
    port			=	11100
    address			=	127.0.0.1
    so_sndbuf		=	16384
    so_rcvbuf		=	16384
    ibuffermax		=	16384
    obuffermax		=	1048576
    accumulate		=	1048576
    
    [LogclientTcpClient]
    type			=	tcp
    port			=	11101
    address			=	127.0.0.1
    so_sndbuf		=	16384
    so_rcvbuf		=	16384
    ibuffermax		=	16384
    obuffermax		=	1048576
    accumulate		=	1048576
    
    [storage]
    homedir			=	/PWServer/gamedbd/dbhomewdb
    datadir			=	dbdata
    logdir			=	dblogs
    backupdir		=	/PWServer/gamedbd/dbhomewdb/backup
    cachesize		=	16777216
    errpfx			=	Storage
    checkpoint_interval	=	60
    backup_lockfile	=	/tmp/.lockgamedbd
    quit_lockfile	=	/tmp/.quitgamedbd
    compress		=	1
    
    [storagewdb]
    homedir			=	/PWServer/gamedbd/dbhomewdb
    datadir			=	dbdata
    logdir			=	dblogs
    backupdir		=	/PWServer/gamedbd/dbhomewdb/backup
    checkpoint_interval	=	60
    times_incbackup	=	1
    tables			=	auction,city,equipment,friends,messages,status,user,clsconfig,factioninfo,inventory,rolename,storehouse,userfaction,base,config,factionname,mailbox,sellpoint,task,translog,waitdel,gtask,order,shoplog
    cache_high_default	=	8000
    cache_low_default	=	7500
    base_cache_high		=	50000
    base_cache_low		=	45000
    status_cache_high	=	50000
    status_cache_low	=	45000
    equipment_cache_high=	50000
    equipment_cache_low	=	45000
    inventory_cache_high=	50000
    inventory_cache_low	=	45000
    backup_lockfile	=	/tmp/.lockgamedbd
    quit_lockfile	=	/tmp/.quitgamedbd
    
    [gamedbd]
    noimportclsconfig	=	0
    
    [ThreadPool]
    threads			=	(0,1)(1,15)(100,1)(101,1)
    max_queuesize	=	1048576
    prior_strict	=	1
    
    #½Ç«λÖÓÓϷ·þÎÆ¶Ô¦¹Øµ
    [GameServerRegion]
    #ID		=	Region[left,right,top,bottom]
    IDs		=	1
    1		=	-100000,100000,100000,-100000
    
    [Role]
    delete_timeout	=	604800
    ;delete_timeout	=	60
    
    #¸÷°ҵµijõÅ¢
    #ְҵµÄD£¬´Ó¿ªʼ£¬´Îò
    [OCCUPATION]
    occupations		=	SWORDSMAN,MAGE,MONK,HAG,ORGE,GENIE,ARCHER,ANGEL
    		
    [GENERAL]
    
    #ÈÀսʿ
    [SWORDSMAN]
    race	=	0
    posx	=	332
    posy	=	241
    posz	=	3068
    money	=	0
    
    hp 		= 	60
    mp		=	20
    vitality	=	20
    energy  	=	5
    strength	=	15	
    agility 	=	10
    
    attack_speed	=	14
    hp_gen		=	30
    mp_gen		=	10
    walk_speed	=	1.5
    run_speed	=	5.0
    swim_speed	=	2.2
    flight_speed	=	5.0
    move_speed	=	1
    
    vit_hp		=	4
    eng_mp		=	2
    lvlup_hp	=	10
    lvlup_mp	=	6
    lvlup_dmg	=	2	
    lvlup_magic	=	1
    lvlup_defense 	=	2
    
    #ÈÀ·¨ʦ
    [MAGE]
    race	=	0
    posx	=	332
    posy	=	241
    posz	=	3068
    money	=	0
    
    hp 		= 	30
    mp		=	50
    vitality	=	10
    energy  	=	20
    strength	=	10
    agility 	=	10
    
    attack_speed	=	20
    hp_gen		=	10
    mp_gen		=	30
    walk_speed	=	1.3
    run_speed	=	5.7
    swim_speed	=	2
    flight_speed	=	5.7
    move_speed	= 	0.9
    
    vit_hp		=	2
    eng_mp		=	4
    lvlup_hp	=	6
    lvlup_mp	=	10
    lvlup_dmg	=	1
    lvlup_magic	=	2
    lvlup_defense 	=	1
    
    #ÈÀɮÂ
    [MONK]
    race	=	0
    posx	=	332
    posy	=	241
    posz	=	3068
    money	=	0
    
    hp 		= 	40
    mp		=	40
    vitality	=	15
    energy  	=	15
    strength	=	10
    agility 	=	10
    
    attack_speed	=	16
    hp_gen		=	20
    mp_gen		=	20
    walk_speed	=	1.4
    run_speed	=	5.9
    swim_speed	=	2.1
    flight_speed	=	5.9
    move_speed	= 	1
    
    vit_hp		=	3
    eng_mp		=	3
    lvlup_hp	=	8
    lvlup_mp	=	8
    lvlup_dmg	=	2	
    lvlup_magic	=	1
    lvlup_defense 	=	2
    
    #Ѿ«
    [HAG]
    race	=	1
    posx	=	332
    posy	=	241
    posz	=	3068
    money	=	0
    
    hp 		= 	50
    mp		=	30
    vitality	=	15
    energy  	=	15
    strength	=	15
    agility 	=	5
    
    attack_speed	=	16
    hp_gen		=	20
    mp_gen		=	20
    walk_speed	=	1.5
    run_speed	=	5.1
    swim_speed	=	2.3
    flight_speed	=	5.1
    move_speed	= 	1.1
    
    vit_hp		=	3
    eng_mp		=	3
    lvlup_hp	=	8
    lvlup_mp	=	8
    lvlup_dmg	=	2	
    lvlup_magic	=	1
    lvlup_defense 	=	2
    
    #ÑÊ
    [ORGE]
    race	=	2
    posx	=	332
    posy	=	241
    posz	=	3068
    money	=	0
    
    hp 		= 	65
    mp		=	15
    vitality	=	25
    energy  	=	5
    strength	=	15
    agility 	=	5
    
    attack_speed	=	14
    hp_gen		=	60
    mp_gen		=	20
    walk_speed	=	1.4
    run_speed	=	5.8
    swim_speed	=	2
    flight_speed	=	5.8
    move_speed	= 	0.9
    
    vit_hp		=	4
    eng_mp		=	2
    lvlup_hp	=	10
    lvlup_mp	=	6
    lvlup_dmg	=	2	
    lvlup_magic	=	1
    lvlup_defense 	=	2
    
    #÷
    [GENIE]
    race	=	3
    posx	=	332
    posy	=	241
    posz	=	3068
    money	=	0
    
    hp 		= 	25
    mp		=	55
    vitality	=	8
    energy  	=	22
    strength	=	5
    agility 	=	15
    
    attack_speed	=	20
    hp_gen		=	10
    mp_gen		=	30
    walk_speed	=	1.6
    run_speed	=	5.3
    swim_speed	=	2.4
    flight_speed	=	5.3
    move_speed	= 	1.2
    
    vit_hp		=	2
    eng_mp		=	4
    lvlup_hp	=	4
    lvlup_mp	=	12
    lvlup_dmg	=	1
    lvlup_magic	=	2
    lvlup_defense 	=	1
    
    #Óâ
    [ARCHER]
    race	=	4
    posx	=	332
    posy	=	241
    posz	=	3068
    money	=	0
    
    hp 		= 	30
    mp		=	50
    vitality	=	15
    energy  	=	15
    strength	=	10
    agility 	=	10
    
    attack_speed	=	14
    hp_gen		=	20
    mp_gen		=	20
    walk_speed	=	1.4
    run_speed	=	5.8
    swim_speed	=	2.0
    flight_speed	=	5.8
    move_speed	= 	0.9
    
    vit_hp		=	3
    eng_mp		=	3
    lvlup_hp	=	8
    lvlup_mp	=	8
    lvlup_dmg	=	2
    lvlup_magic	=	1
    lvlup_defense 	=	2
    
    #ÓÁ
    [ANGEL]
    race	=	5
    posx	=	332
    posy	=	241
    posz	=	3068
    money	=	0
    
    hp 		= 	30
    mp		=	50
    vitality	=	10
    energy  	=	25
    strength	=	5
    agility 	=	10
    
    attack_speed	=	20
    hp_gen		=	10
    mp_gen		=	30
    walk_speed	=	1.4
    run_speed	=	5.8
    swim_speed	=	2.0
    flight_speed	=	5.8
    move_speed	= 	0.9
    
    vit_hp		=	2
    eng_mp		=	4
    lvlup_hp	=	6
    lvlup_mp	=	10
    lvlup_dmg	=	1
    lvlup_magic	=	2
    lvlup_defense 	=	1
    uniquenamed
    Code:
    [uniqueNameServer]
    type                    =       tcp
    port                    =       29401
    address                 =       127.0.0.1
    so_sndbuf               =       16384
    so_rcvbuf               =       16384
    ibuffermax              =       1048576
    obuffermax              =       1048576
    tcp_nodelay             =       0
    listen_backlog  =       10
    accumulate              =       16777216
    isec                    =       2
    iseckey                 =       baxitf91jvrQarnjwbyvlcdxqdvuqp
    osec                    =       2
    oseckey                 =       baxiyEwt4fuqrysyoylfy7Fxbmhobo
    
    [LogclientClient]
    type			=	udp
    port			=	11100
    address			=	127.0.0.1
    so_sndbuf		=	16384
    so_rcvbuf		=	16384
    ibuffermax		=	16384
    obuffermax		=	1048576
    accumulate		=	1048576
    
    [LogclientTcpClient]
    type			=	tcp
    port			=	11101
    address			=	127.0.0.1
    so_sndbuf		=	16384
    so_rcvbuf		=	16384
    ibuffermax		=	16384
    obuffermax		=	1048576
    accumulate		=	1048576
    
    [storage]
    homedir			=	/PWServer/uniquenamed/uname
    datadir			=	dbdata
    logdir			=	dblogs
    backupdir		=	/PWServer/uniquenamed/uname/backup
    cachesize		=	16777216
    errpfx			=	Storage
    checkpoint_interval	=	60
    backup_lockfile	=	/tmp/.lockuniquenamed
    ;compress		=	1
    
    [storagewdb]
    homedir         =   /PWServer/uniquenamed/uname
    datadir         =   dbdata
    logdir          =   dblogs
    backupdir       =   /PWServer/uniquenamed/uname/backup
    checkpoint_interval =   60
    times_incbackup     =   24
    tables          =   config,uidrole,unamefaction,unamerole
    cache_high_default  =   16384
    cache_low_default   =   10000
    ;base_cache_high        =   4096
    ;base_cache_low     =   1024
    ;status_cache_high  =   4096
    ;status_cache_low   =   1024
    ;equipment_cache_high   =   4096
    ;equipment_cache_low    =   1024
    ;inventory_cache_high   =   4096
    ;inventory_cache_low    =   1024
    backup_lockfile     =   /tmp/.lockuniquenamed
    quit_lockfile       =   /tmp/.quituniquenamed
    
    [ThreadPool]
    threads			=	(0,1)(1,5)(100,1)(101,1)
    max_queuesize	=	1048576
    prior_strict	=	1
    oh wait, looks like I had another account at the beginning..... I found my GM toon

  12. #12
    Proficient Member Souris is offline
    MemberRank
    Feb 2009 Join Date
    167Posts

    Re: Zomg help!

    I'd guess maybe the permission on the gamedb data files did not let you copy them. Can you show the output of "find /path/to/backup"? (if you put your backup in PWServer2, what does "find /PWServer2" output)

    @343: don't you need to backup /PWServer/uniquenamed/uname/dbdata too ?

    Edit: your config shows your data is indeed in /PWServer and since you found your toon I assume you did backup it! Just missing the mysql info then like 343 said.

  13. #13
    Omega 343 is offline
    MemberRank
    Oct 2009 Join Date
    Ancient DGN CTYLocation
    5,514Posts

    Re: Zomg help!

    Actually when I tested you do NOT have to back up uniquename too

    I tested restoring a 'backup' without also doing uniquenamed's DB and thought it would 'break' when it would most likely allow characters with duplicate names to be made, so I restored w/o uniquenamed and tried to make a character with my name, and it knew it was already taken... So I am pretty sure uniquenamed is updated automatically based off of gamedbd

  14. #14
    Member Allisandre is offline
    MemberRank
    Dec 2011 Join Date
    MichiganLocation
    68Posts

    Re: Zomg help!

    Yes, all is happy in my land now. I've just got to re-create the accounts and let everyone know what their login data is now. I should be back in business within the hour.

    Again guys, thank you heaping loads for all of your help. I was totally lost.

  15. #15
    Proficient Member Souris is offline
    MemberRank
    Feb 2009 Join Date
    167Posts

    Re: Zomg help!

    Did you test faction names too? Would make sense if it is automatically updated, not sure i'd trust it though XD

    @Allisandre on a side note, to backup mysql have a look at mysqldump

  16. #16
    Omega 343 is offline
    MemberRank
    Oct 2009 Join Date
    Ancient DGN CTYLocation
    5,514Posts

    Re: Zomg help!

    I'll trust it

    You can use any method to 'dump' the MySQL DB -- personally I usually use Navicat (included on my PW_DEV.iso)

    you could even use PHPMYADMIN if you want to

  17. #17
    Member Allisandre is offline
    MemberRank
    Dec 2011 Join Date
    MichiganLocation
    68Posts

    Re: Zomg help!

    no haven't logged in yet to test faction names. I'll do that now

    yes faction names are still good. lost the husband/wife thing, but that was already screwed up. Married the toons through pwAdmin, and after a couple of losing, one lost the spouse name and one didn't. now both don't have.

  18. #18
    PW Dev <3 Ozuru is offline
    MemberRank
    Feb 2011 Join Date
    737Posts

    Re: Zomg help!

    Quote Originally Posted by Allisandre View Post
    no haven't logged in yet to test faction names. I'll do that now

    yes faction names are still good. lost the husband/wife thing, but that was already screwed up. Married the toons through pwAdmin, and after a couple of losing, one lost the spouse name and one didn't. now both don't have.
    T-T this has been discussed so many times on ragezone that when I see a post like that, I want to cry. Search for mirage information. You marry them, force log, and then wait > 15 minutes.

  19. #19
    RaGEaholic crxfreak is offline
    MemberRank
    Jul 2011 Join Date
    United StatesLocation
    625Posts

    Re: Zomg help!

    Actually I have had luck with making them stay logged in, in the same squad for at least 15 mins after. Best way I can think to do this with 343's release is to recreate the marriage quests inside the chapel with the ex's and such. That will possibly keep them in the same map in squad for that length of time.



Advertisement