Changing to new HDD...Time Machine?

I'm going to buy a new bigger HDD for my MBP and I am having questions about transfering data (easily) onto my new HDD. How can this issue be resolved with Time Machine? Also, if I take my Install/Restore Mac OSX discs to the Apple Store with me, could they put it in the new HDD and install Mac OSX for me, on the spot?
Essentially, I just want to turn on my laptop and be ready to roll, start up Time Machine and start the copying of files to the new HDD...
Can this be done?
Thanks!

Hi petrucci666;
You will be using an external for Time Machine?
If you have your system and Time Machine on Partition on the same drive when you lose the drive, which is the most common occurrence, then you lose everything.
Allan

Similar Messages

  • How do I change backup frequency on time machine?

    How do I change backup frequency for time machine?

    You have met the infamous User Account Number issue, which causes denied access to previous user accounts.
    A simple install creates a user account with a number, usually 501.  If you use Setup Assistant at this point, to bring across your data from the previous OS, it will have the same number and access between the two is ok.  If you wait and use Migration Assistant later, it creates a new user account, say with number 502. Now this account can't access the original data.
    You can see this number in System Preferences>Users & Groups.  Right click on your account name and go into Advanced Options.  DON"T CHANGE ANYTHING.
    Look at Pondini's guide for a second chance to use setup assistant...
    http://pondini.org/OSX/Setup.html

  • How can I move (copy) my Time Capsule date to a new 2T hard drive and then wipe the TC and start as a new (clean) Time MACHINE backup?

    How can I move (copy) my Time Capsule date to a new 2T hard drive and then wipe the TC and start as a new (clean) Time MACHINE backup?

    Just use the archive utility on the disk page of the airport utility manual setup..
    If you have lion and v6 airport utility.. it missed out. On lots of things.
    Download and install the real.. UTILITY
    5.6 http://support.apple.com/kb/DL1482

  • Change which old backups Time Machine keeps

    Any body know how to change what older backups Time Machine keeps?  I know how to change how frequently Time Machine backs up (sudo defaults write /System/Library/LaunchDaemons/com.apple.backupd-auto StartInterval -int XXXX),
    but what I want is for it to not save so many recent backups and keep more of the old ones.  Right now it saves hourly backups for the last 24 hours, daily for the last month, and weekly for each month until you run out of space.  I don't need all the daily stuff, and would really like to keep more of the monthly.  The older the info, the harder it is to recover by other means.  What I'd like to do is keep older backups and lose more of the intermediate ones.
    Any ideas?

    If you have more than one user account, these instructions must be carried out as an administrator.
    Launch the Console application in any of the following ways:
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
    ☞ Open LaunchPad. Click Utilities, then Console in the icon grid.
    Make sure the title of the Console window is All Messages. If it isn't, select All Messages from the SYSTEM LOG QUERIES menu on the left.
    Enter the word "Starting" (without the quotes) in the String Matching text field. You should now see log messages with the words "Starting * backup," where * represents any of the words "automatic," "manual," or "standard." Note the timestamp of the last such message. Clear the text field and scroll back in the log to that time. Post the messages timestamped from then until the end of the backup, or the end of the log if that's not clear.
    Post the log text, please, not a screenshot. If there are runs of repeated messages, post only one example of each. Don't post many repetitions of the same message.
    When posting a log extract, be selective. Don't post more than is requested.
    Please do not indiscriminately dump thousands of lines from the log into a message.
    Some personal information, such as the names of your files, may be included — edit that out, too, but don’t remove the context.

  • Migration to new 3TB Time Machine/Time Capsule?

    From an earlier posting, I think A Silverstone asked for a step-by-step procedure.
    I have a similar issue I would like a procedure(s) on.  Actually two identical issues.
    1. I wish to purchase Apples new 3TB tower Airport/Time Machine to replace a 1TB Airport extreme/Time Machine.  I want to migrate the old to the new using Apple processes/procedures without a lot of workaround.  How can this be done?  Does Apple have a procedure?
    2. I have a desktop with four drives (three 2TB & one 1TB) and wish at least two of them to be Time Machine capable, i.e., backup every hour like the Airport/Time Machine does.  Can this be done?  Does Apple have a procedure?
    I want to migrate the old Time Capsule data to the new Time Capsule and to two HD's in the desktop.
    The idea is to have backups for a Time Machine backup in the event of a power disruption or a hacker that might impact the tower Time Machine.  There are other reasons such as storage capacity using a daisy chain process.
    One main problem is capturing the old "sparsebundle" in such a way to get it into the new unit and on to internal HD's.  How to do this is the question.

    1. Time Machine – Transfer Backup to a New Drive
    Time Machine – Transfer Backup to a New Drive (2)
    You can also use Disk Utility's Restore tab, which is often faster and less prone to errors. Note it will format the new drive.
    2. Yes. Go to System Preferences/Time Machine, select Add a drive and you can have 2. They will alternate with each new backup.
    OS X Mavericks: Use multiple backup disks

  • Just moved CS4 Web from old mac to new using time machine. Apps won't launch. Help?

    Just moved CS4 Web from old mac to new using time machine. I get an error when I try to launch a program on the new computer (150:30). After contacting live chat about the issue and providing all serial numbers etc. I was directed to a download. The download was a .dmg file that my computer did not recognize. It was suggested that I ask the experts on the forum how to resolve the issue. I have all the discs and serial numbers but the new macbook pro doesn't take discs (I guess they think all apps are downloadable now). Any ideas?

    Hmm... I don't know why they sent you here... CS4 is not part of the Cloud
    I have some download links for earlier versions of Premiere Pro and Premiere Elements, but not CS4 Web
    My best idea is to take a LARGE USB memory stick to a friend with a DVD drive and copy your DVD over to the USB memory stick
    Or, ask in the forum for your program(s) to find out if anyone has CS4 download links
    If you start at the Forums Index https://forums.adobe.com/welcome
    You will be able to select a forum for the specific Adobe product(s) you use
    Click the "down arrow" symbol on the right (where it says All communities) to open the drop down list and scroll

  • SSD/HDD Time Machine Back Up Issue

    I am having an issue with my 2010 13" MacBook Pro.
    A few months ago I removed the optical drive, replaced it with the existing HDD, and then replaced the HDD with an SSD.
    The SSD runs my OS (Mountain Lion 10.8.4) and Applications, while the HDD is where I store my Home Folder.
    I did a Time Machine Back Up in March using a SeaGate external hard drive, with no issues.
    Last week I updated the Time Machine Back Up using the same external hard drive, but this time something has gone wrong.
    I am unable to move files within my system without Finder prompting me for a password.
    I am unable to write to any external USB as I do not have 'permission to perform some actions'.
    I am unable to connect to external servers via VPNs.
    Finder does not open a new window when slected, I am forced to press 'Comman+N' every time.
    Numerous other issues.
    I have read that it's an issue to do with ACL's, but since my Home Folder is not on my Startup Disk, there is no way for me to do this.
    I am the only account on the computer, and both drives have 'Read & Write' permissions.
    Does anyone know how to fix this issue?
    Please feel free to ask for more details.
    Thanks.

    Please read this whole message before doing anything.
    This procedure is a diagnostic test. It won’t solve your problem. Don’t be disappointed when you find that nothing has changed after you complete it.
    Third-party system modifications are a common cause of usability problems. By a “system modification,” I mean software that affects the operation of other software — potentially for the worse. The following procedure will help identify which such modifications you've installed. Don’t be alarmed by the complexity of these instructions — they’re easy to carry out and won’t change anything on your Mac. 
    These steps are to be taken while booted in “normal” mode, not in safe mode. If you’re now running in safe mode, reboot as usual before continuing. 
    Below are instructions to enter some UNIX shell commands. The commands are harmless, but they must be entered exactly as given in order to work. If you have doubts about the safety of the procedure suggested here, search this site for other discussions in which it’s been followed without any report of ill effects. 
    Some of the commands will line-wrap or scroll in your browser, but each one is really just a single line, all of which must be selected. You can accomplish this easily by triple-clicking anywhere in the line. The whole line will highlight, and you can then copy it. The headings “Step 1” and so on are not part of the commands. 
    Note: If you have more than one user account, Step 2 must be taken as an administrator. Ordinarily that would be the user created automatically when you booted the system for the first time. The other steps should be taken as the user who has the problem, if different. Most personal Macs have only one user, and in that case this paragraph doesn’t apply. 
    Launch the Terminal application in any of the following ways: 
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.) 
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens. 
    ☞ Open LaunchPad. Click Utilities, then Terminal in the icon grid. 
    When you launch Terminal, a text window will open with a line already in it, ending either in a dollar sign (“$”) or a percent sign (“%”). If you get the percent sign, enter “sh” and press return. You should then get a new line ending in a dollar sign. 
    Step 1 
    Triple-click the line of text below on this page to select it:
    kextstat -kl | awk '!/com\.apple/{printf "%s %s\n", $6, $7}' | open -f -a TextEdit 
    Copy the selected text to the Clipboard by pressing the key combination command-C. Then click anywhere in the Terminal window and paste (command-V). A TextEdit window will open with the output of the command. If the command produced no output, the window will be empty. Post the contents of the TextEdit window (not the Terminal window), if any — the text, please, not a screenshot. You can then close the TextEdit window. The title of the window doesn't matter, and you don't need to post that. No typing is involved in this step.
    Step 2 
    Repeat with this line:
    { sudo launchctl list | sed 1d | awk '!/0x|com\.(apple|openssh|vix)|org\.(amav|apac|cups|isc|ntp|postf|x)/{print $3}'; sudo defaults read com.apple.loginwindow LoginHook 2> /dev/null; } | open -f -a TextEdit 
    This time you'll be prompted for your login password, which you do have to type. Nothing will be displayed when you type it. Type it carefully and then press return. You may get a one-time warning to be careful. Heed that warning, but don't post it. If you see a message that your username "is not in the sudoers file," then you're not logged in as an administrator. 
    Note: If you don’t have a login password, you’ll need to set one before taking this step. If that’s not possible, skip to the next step. 
    Step 3
    launchctl list | sed 1d | awk '!/0x|com\.apple|org\.(x|openbsd)/{print $3}' | open -f -a TextEdit 
    Step 4
    ls -1A /e*/{la,mach}* {,/}L*/{Ad,Compon,Ex,Fram,In,Keyb,La,Mail/Bu,P*P,Priv,Qu,Scripti,Servi,Spo,Sta}* L*/Fonts .la* 2> /dev/null | open -f -a TextEdit  
    Important: If you formerly synchronized with a MobileMe account, your me.com email address may appear in the output of the above command. If so, anonymize it before posting. 
    Step 5
    osascript -e 'tell application "System Events" to get name of every login item' | open -f -a TextEdit 
    Remember, steps 1-5 are all copy-and-paste — no typing, except your password. Also remember to post the output. 
    You can then quit Terminal.

  • Restoring data on new drive, time machine can't find old drive because it backed up my old clone drive instead. now what?

    My hard drive failed on MB Pro 2008. i was able to start up using a super duper bootable clone on an iomega external drive (the clone was from 6 months ago unfortunately). once the computer started up, it saw the failed drive and i was able to retrieve some new data created since my last time machine backup 10 days ago. i then plugged in another external drive with my time machine backup on it and tried  to backup the failed harddrive once more before going to buy a new HD and getting rid of the failed one. INSTEAD  of backing up the real HD, time machine backed up the clone drive which is 6 months old. now that i have a new HD and OS 10.6.3, when i try to restore data from the last time machine backup of the real HD (12/27/12), the only option i'm getting is from the backup of the CLONE drive which is 6 months older. i know the info is there but the transfer data option isn't seeing that drive. what do i do???

    If I understand you correctly, you have a Clone of your original internal HDD and a Time Machine HDD that backed up the Clone.  If it backed up the Clone HDD and deleted the prior backups, then your data is gone.  If it backed up the Clone for only the changes made since the Clone was created, the data should be there.
    Open Time Machine and see what actually is there.  If you cannot open it,  Click on the Time Machine icon on your desktop.  It will give you a display showing one folder (Backups.backupdp).  Open that folder and it will show another single folder.  Open that one and it should display folders that are dated for each day/week that backups have been made.
    If there are 'old' folders in there, you can access the data by opening then up as the image below indicates:
    It may be tedious, but it is better than not having the data.
    Ciao.

  • Changing the name of time machine

    Okay this is a preemptive, I have an external with three partitions, 1 is for bulk files that won't fit on my Laptop, 1 is for a backup of my PS3, 1 is for my Time Machine. I was wondering if I could change the name of my Time Machine drive as the one I have is not clear and I don't want my girlfriend to mess things up. I suspect that just changing it will mess the whole Time Machine process up so is there either a work around to confuse it that the old saves were indeed on the drive with the new name? I know the sparsebundle file is finicky, of course cause its a backup.
    I wanted to ask before I did anything.
    I have read this but not sure if I need to go down a similar route http://www.hardmac.com/blog/2008/05/29/how-i-saved-my-corrupted-time-machine-spa rsebundle-image
    Thanks in advance

    Mad-elph wrote:
    Okay this is a preemptive, I have an external with three partitions, 1 is for bulk files that won't fit on my Laptop, 1 is for a backup of my PS3, 1 is for my Time Machine. I was wondering if I could change the name of my Time Machine drive as the one I have is not clear and I don't want my girlfriend to mess things up. I suspect that just changing it will mess the whole Time Machine process up so is there either a work around to confuse it that the old saves were indeed on the drive with the new name? I know the sparsebundle file is finicky, of course cause its a backup.
    If you're backing-up to a directly-attached, partitioned HD, all you have to do is change the name of the TM partition (not the drive itself).
    Open a Finder window. If the partition doesn't show in it's sidebar, click Finder > Preferences > Sidebar in the menubar, then check the box to make external drives appear.
    Back to the Finder window, control-click (right-click) the partition name and select the Rename option. This is one of the very few things you can rename that will not confuse TM. The new name will appear automatically in TM Preferences, for example, and backups will continue in the normal fashion.

  • Changing account name affects Time Machine?

    Hi,
    I would like to change the account name of the main user (it currently has the generic name "admin") according to Apple's instructions.
    I was wondering though if and how this will affect Time Machine. The full name (editable via the user & login system prefs) will remain the same, as well as the computer name in the Sharing prefs.
    Will TM create a new backup folder instead of continuing the existing backup?
    Thanks

    If you change the short user name (home folder name), Time Machine will back it up in full, and prior backups of it won't appear as they used to.  But you can still see them, per the pink box in Time Machine - Frequently Asked Question #15A.

  • Changed Hard Disk for Time Machine

    I have a question, I've searched and can't find the answer (maybe I'm just not good at searching).
    I ran out of room on my external HD for time machine backups, so I added another external HD and changed the time machine location to the new HD. I did not copy any backup files to the new HD, I figured that I'd just keep the old ones on the old HD and start from scratch.
    I am using an old iMac G5 that has one (yes, one) USB2.0 port, the other USB ports are the old, slow ones. I have the new HD plugged into the USB2.0 port and the old HD plugged into one of the other ones.
    Then I selected "back up now," and it's been backing up for more than 12 hours and it's only about 1/3 of the way done according to the progress report (37.4 GB of 96.9 GB).
    Question -- does time machine automatically copy my old back up from the old HD to the new HD? That's the only thing that I can think of that would make this back up so slow. It shouldn't take 12 hours to back up 37 GB, right?

    Thanks. I think I need to just wait until it's done and then check things out. I let it run all day while I was at work, and it's another 1/3 of the way to the end. I don't want to stop it and then find out that I just need to let it run its course.
    Here is the backup log from the time machine widget:
    Backing up to: /Volumes/Backup/Backups.backupdb
    2010-06-22 18:33:57.446 FindSystemFiles[1245:713] Querying receipt database for system packages
    2010-06-22 18:34:02.962 FindSystemFiles[1245:713] Using system path cache.
    2010-06-22 18:34:03.335 FindSystemFiles[1250:713] Querying receipt database for system packages
    2010-06-22 18:34:04.293 FindSystemFiles[1250:713] Using system path cache.
    Event store UUIDs don't match for volume: Storage Central
    Event store UUIDs don't match for volume: Alternate Storage
    No pre-backup thinning needed: 116.45 GB requested (including padding), 376.49 GB available
    Copied 11 files (0 bytes) from volume Storage Central.
    Event store UUIDs don't match for volume: Storage Central

  • Cannot change case-sensitivity of Time Machine sparse bundle (10.7.2)

    Hi everyone, I'm trying to follow this excellent guide to Time Machine backups:
    http://pondini.org/TM/A8.html
    The site suggests that I make my TM backup case INsensitive, so after the network sparse bundle has been initially created on my Lion 10.7.2 TM backup, I cancelled the backup, then opened up the sparse bundle in Disk Utility as per the instructions provided.
    I double clicked the sparse bundle to open the Time Machine Backups volume, and then in the Erase tab I changed the format from Mac OS Extended (Case-sensitive, Journaled), to Mac OS Extended (Journaled).
    Then I clicked on "Erase" but it returned an error and said it could not do it. Sorry I don't have the exact error message on hand at the moment but it happened again with the same error message when I tried again.
    Steps 6-8 in the guide tell me to Get Info on the Time Machine Backups volume and "Ignore ownership on this volume". However when I open the Info for the volume "Ignore ownership on this volume" is not there at all in the options? I've opened up every section of the Get Info window but it's definitely not present.
    Has something changed in 10.7 Lion or is there another reason I'm getting this problem? The HDD is connected as an AirDisk on an AirPort Extreme Base Station (yes I realise this is an unsupported/not recommended Time Machine solution). I haven't yet tried directly plugging the drive in via USB which will be my next step when I regain access to my computer later.
    Any help or advice would be appreciated. Many thanks.

    owngoal wrote:
    You say your "backups still turn up corrupted now and then" - how do you know? Is it only when you try to access them that you will know this?
    Sometimes a backup will fail, sometimes you can't access them, sometimes you'll get this message:
    See #C13 in Time Machine - Troubleshooting for details.
    And by this stage is it too late to recover anything?
    Sometimes.    Sometimes they can be repaired by Disk Utility.  Sometimes only a heavy-duty 3rd-party disk repair app like DiskWarrior ($100) can fix them.  Sometimes nothing can.  Sometimes you can restore some individual items, sometimes not.  Sometimes you can do a full system restore from some backups, other times not.
    does it help that I am using a Gigabit WIRED connection between iMac - 10/100/1000 switch - Airport Extreme Base Station?
    Probably -- you won't have WIFI interference.
    But if you have an iMac, why not just connect the external HD directly to your Mac?  That's much faster and more reliable (and supported).
    You'd need to erase the disk in that case, since Time Machine won't bother with a sparse bundle at all on a direct backup.  Just format the disk as GUID, with Mac OS Extended (Journaled) and let 'er rip!

  • With a new exHD, time machine seems to copy backups, then stalls.

    Hi, my old external hard drive backup, a MyBook, is filling up, so I bought a Seagate Backup Plus to take over the Time Machine backups. I formatted and partitioned the new EHD, and it seemed to start the process of copying the TM backups. But then I get a message:" You may need to enter the name and password for an administrator on this computer to change the item named backups.backupdb."
    However, it gives me no option to entering the name and password. It basially gives me the option of Skipping, continuing, or stopping. Any choice results in the copying progress bar freezing.
    In addition I *did* give the name and password at the beginning of the process. So I really don't understand what's going on. Also, I am able to copy old files from the MyBook to the second partition on the Seagate with no problem.
    Could the size of the TM backup be an issue? It's about 1.5 TB.
    Appreciate any help, thanks.

    Thanks Eric,
    I have followed the steps in the first link. It's in the copying the old drive backup to the new drive where the freeze happens.
    I've also had Disk Utility check the disks, which seem OK.
    One thing I'm noticing now is that I do *not* see the "Ignore ownership" check box in the Sharing and Permissions" section for the new Time Machine partition, which is weird, because I'm pretty sure the first time I tried it, it was there. That check box is still visible in the other partition, but not in the partition I've created for Time Machine. I have no idea what it means.
    Not sure what else to try. I may try to contact Seagate support tomorrow and just see how responsive they are.
    Thanks again.

  • Change background colors of time machine

    The new color scheme in time machine is absolutely horrible.  I can no longer see the list on the right, with a purple on purple background.
    I called support and got some idiot that just popped off, can't be done, good bye. 
    There has to be a way to change that, can someone help me out here, I can't read the list at all any more

    This is an unsupported and untested hack. I don't know whether it still works. Although I don't generally advise hacking on this site, it seems justified in your case.
    Back up all data.
    Triple-click anywhere in the line below on this page to select it:
    defaults write com.apple.finder _FXShowBackgroundAnimation -bool FALSE
    Copy the selected text to the Clipboard (command-C).
    Launch the Terminal application in any of the following ways:
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
    ☞ Open LaunchPad. Click Utilities, then Terminal in the icon grid.
    Paste into the Terminal window (command-V).
    Relaunch the Finder.
    To undo, repeat the above steps with this command:
    defaults delete com.apple.finder _FXShowBackgroundAnimation

  • Why does ext HDD / time machine run slow?

    Apologies if this is answered else where, but I can't find any answers.
    I have a MBP running OSX 10.6.8. Connected to it as a Time Machine is a Freecom 400GB 28147 uk, external hardrive connected over USB 2.0. I also have a Mac Mini running 10.6.8.
    When connected to my MBP, I have found that it is extremely slow to read files. I gave up using it for Time Machine a while ago as I thought there was a problem Time Machine software causing it to run slow. I have also tried to read the time machine backups through finder and they are still slow to read.
    Today (don't know why i didn't do it before now) I plugged it in to my Mac Mini with USB 2.0 and found that I can read all the time machine files at lightning speed, far quicker than my MBP which can take 2-3 mins to open a folder. I have noticed that the hard drive doesn't make its usual whurring noise when im trying to open a folder using the MBP, right up until the last minute before the folder opens.
    Does any one have any idea about what might be causing the problem when the the ext HDD is connected to my MBP?
    Any thoughts or suggestions greatly appreciated.

    larryfromjackson wrote:
    I'm backing up to a Drobo with four 2-Gig drives.
    How are you connected to it? Network problems could explain at least some of what you're seeing.
    More often then not I don't know how long the backups take because when it becomes to annoying I stop the backup.
    That guarantees that Time Machine will have to do a "deep scan" the next time, comparing everything on your system to the backups.   That does take a while, but if there are no other problems shouldn't have a major impact on performance.
    All of that said, I can't say for certain that there isn't something else going on.  Generally the way I notice the slowdown is when my keyboard inputs come out screwy -- ingB instead of Bring, pplAication for Applicaton for example.  When I know that this is happening I can work "around" it by typing the first letter, pausing for a second or two, then typing the remander.  Does any of this ring an bells?
    I've not heard of that specifically, but if you're connected to the Drobo wirelessly, and using a Bluetooth keyboard, there are reports of interference between the two. Try a wired keyboard temporarily, and/or different WIFI channels.

Maybe you are looking for

  • How to get the Double-sided print in SMARTFORM?

    Hi Folks, Can u  explain me , how to get the Double-sided print ? I create two pages : Page 1 and Page 2. Page 1 contains Main Window and some text data in it..... Page 2 contains  a secondary window with some TERMS & CONDITIONs data. Print Mode Sett

  • Troubleshooting Leopard printing problems

    Leopard printing problems fall into several categories a) Faulty or missing Leopard print driver b) Faulty implementation of the print command from the active application c) Faulty equipment, eg printer, cables, etc d) Faulty networking/sharing e) Fa

  • Can we have two document types in SAP_SRM5.0?

    Hi All, Can we have two document types in SAP_SRM5.0? The doc type EC is configured for EC-PR and PO , But now we need to rollout buyers intervenes if sc< 5000K, should generate the PO directly for non-catalog. For instance; 1.     Existing scenario,

  • Online Emulator for RV042 router

    Hello: I am looking for Online Emulator for RV042 router. If yes, please reply with a link. If no, please give me a similar one. Many thanks.

  • ATTEMPTED TO REGISTER MY LIGHTROOM 5 TO BE TOLD THAT THE REDEMPTION CODE IS NOT VALID

    I installed Lightroom 5 onto my computer.  Attempted to register by going to the website adobe.com/go/getserial.  After entering my redemption code I received a message stating that the redemption code was not valid.  I double checked the code before