'Invalid node structure', 'Invalid B-tree node size', Disk Warrior useless

Hi everyone, I am getting sick of this, it's the second time it's happened to me in a relatively short space of time, the first time with an Iomega external 500GB drive, this time with a 1.5TB Western Digital.
I gave the Western Digital drive two partitions, (as I did for the previous Iomega drive), one for doing backups of my MacBooks internal drive, the other for random media, mostly VIDEO_TS folders.
After going away for a couple of weeks, I returned home, plugged in the Western Digital drive via USB, the Internal backup partition showed in Finder, the other did not. Obviously I ran Disk Utility which was only able to show an error report with the usual 'Invalid node structure etc' message.
I tried running Disk Warrior 4.2 (supposedly the version which works with Snow Leopard) from the DVD, (holding down the C key after restart), and..... nothing, just the grey screen and spinning wheel showing, so I gave up on that and installed DW to the Utilities folder. Now it starts up, the corrupt drive showed up, I hit the Rebuild button in DW, things seemed to be happening, but then the Beach Ball appeared and there was a (very) long hang before I decided to Force Quit.
I am assuming that if DW can not fix the drive, it is done for, and may as well be used as a door stop.
I am prepared to buy yet another drive, but can someone please give me an idea about why this has happened to me twice now, and what I can do to prevent it from happening again?

Just erase the partition. Nothing yet suggests the drive is bad. When you got the drive did you prep it correctly? Usually bare drives are pre-formatted for Windows. You might consider doing this:
Extended Hard Drive Preparation
1. Open Disk Utility in your Utilities folder.
2. After DU loads select your hard drive (this is the entry with the mfgr.'s ID and size) from the left side list. Click on the Partition tab in the DU main window.
3. Under the Volume Scheme heading set the number of partitions from the drop down menu to two and size them as you prefer. Set the format type to Mac OS Extended (Journaled.) Click on the Options button, set the partition scheme to GUID then click on the OK button. Click on the Partition button and wait until the process has completed.
4. Select the volume you just created (this is the sub-entry under the drive entry) from the left side list. Click on the Erase tab in the DU main window.
5. Set the format type to Mac OS Extended (Journaled.) Click on the Options button, check the button for Zero Data and click on OK to return to the Erase window.
6. Click on the Erase button. The format process can take up to several hours depending upon the drive size.
Repeat Steps 4-6 for the other partition. Alternatively, you can start with a single volume. After the zero data erase you can then re-partition the drive.

Similar Messages

  • HD crash.  Disk utility says invalid node structure, invalid record count.  Disk utility cannot repair. Now what?

    My hard drive crashed.  The disk utility says it can not repair.  I tried to boot in safe mode but I stopped after 10 minutes.  Is that impatient or how long can it take?
    I have the installation disk but doesn't that erase everything?

    I have never bought a new computer from Apple so I don't know the details of what is covered by the warranty.  You can try taking it to the Apple Store and they may have a copy of DW they can run.  Or maybe not and they will just wipe the drive and reinstall the OS for you and if you haven't made a backup before they do that then tough luck.  I'd check first!
    If you buy Diskwarrior on DVD it will boot the computer.  I think Apple Stores carry it, but you can also buy it directly from the vendor. I also don't use Lion OS so I don't know the details.  You may be able to get their download version and boot from your recovery partition, then run it without a DVD.

  • Join differend source node structures to one destination node

    Hello world,
    I am currently struggling with a mapping where I try to create destination structures from different source structures. In the following xml I tried to illustrate my target:
    <sourceMessage>
    <part1>
    <struct1>
    <key>1</key>
    <value>hello</value>
    </struct1>
    <struct1>
    <key>2</key>
    <value>hello</value>
    </struct1>
    <struct1>
    <key>3</key>
    <value>hello</value>
    </struct1>
    </part1>
    <part2>
    <struct2>
    <id>4</id>
    <content>world</content>
    </struct2>
    <struct2>
    <id>5</id>
    <content>world</content>
    </struct2>
    </part2>
    </sourceMessage>
    <destinationMessage>
    <struct>
    <key>1</key>
    <value>hello</value>
    <source>struct1</source>
    </struct>
    <struct>
    <key>2</key>
    <value>hello</value>
    <source>struct1</source>
    </struct>
    <struct>
    <key>3</key>
    <value>hello</value>
    <source>struct1</source>
    </struct>
    <struct>
    <key>4</key>
    <value>world</value>
    <source>struct2</source>
    </struct>
    <struct>
    <key>5</key>
    <value>world</value>
    <source>struct2</source>
    </struct>
    </destinationMessage>
    I tried to solve this by using a Table Loop Functoid: First input is <Struct1>, second is the number of lines I need, namely 3, next input values are <key> and <value> of <Struct1> ,<Struct2> , <id> and <content>
    and constant values for the destination message to declare the <source> value, "struct1" and "struct2"
    next I declared the table looping grid:
    first row: key, value, "struct1", second row: id, content, "struct2"
    When extracting the result with a Table Extractor Funtoid to the destination schema I am facing the problem that I always get a pair of <struct1> and <struct2> depending on the count of <struct1> in the source message. the values from <struct1>
    are correct, the values from <struct2> are always repeating the first <struct2>...
    so this is what I get as result:
    <destinationMessage>
    <struct>
    <key>1</key>
    <value>hello</value>
    <source>struct1</source>
    </struct>
    <struct>
    <key>4</key>
    <value>world</value>
    <source>struct2</source>
    </struct>
    <struct>
    <key>2</key>
    <value>hello</value>
    <source>struct1</source>
    </struct>
    <struct>
    <key>4</key>
    <value>world</value>
    <source>struct2</source>
    </struct>
    <struct>
    <key>3</key>
    <value>hello</value>
    <source>struct1</source>
    </struct>
    <struct>
    <key>4</key>
    <value>world</value>
    <source>struct2</source>
    </struct>
    </destinationMessage>
    Any ideas of what I am doing wrong here? Any other ideas how to solve this?
    Thanks in advance

    Hi,
    You can just use the Looping Functoid with the first parameter as "struct1" and second parameter as "struct2" and the output mapped to "struct". Rest of the links mapped one to one.
    Map the struct1 node & struct2 node one by one to source in the destination schema with Source Link property as "Copy Name" for both links.
    Hope this will help.
    HTH,
    Sumit
    Sumit Verma - MCTS BizTalk 2006/2010 - Please indicate "Mark as Answer" or "Mark as Helpful" if this post has answered the question

  • How can you repair "invalid node structure and invalid b-tree node size"

    I have a MacBook Pro 17"  and the original install disk is Mac OS 10.4.  I have an update 10.6 install CD, but I cannot use it to boot up my computer.  My computer had been running on 10.6 when the problem occurred.
    It seems my harddrive has crashed. It only boots to apple logo and spins.  I have reset the pram. Started up in safe mode with shift pressed down and started up on the start up disk,  where I did repair disk and got this "invalid node structure invalid b-tree node size".  Then it said repair failed to complete.  I tried booting again but it still failed. I thought doing a restore might solve the problem.  I have a month old backup with time machine which is on a lacie external drive, but when I try to restore using my original 10.4 install disk, I can only choose the lacie hardrive icon (by dragging) and cannot choose the folder in the backups with the latest backup.  When I tried to restore, it says my source is not a valid option.  Is this because it is a 10.4 startup disk.
    Basically I have two questions:  Is there a way to fix my problem without doing a restore and if I have to restore, how do I restore my time machine backup?  Will I need to do a reinstall with 10.4 and then update to 10.6?
    I really hope to find a way to have my computer back to how it was when it started spinning and if not, at least as it was when I did the latest backup 3 weeks ago. 
    Please help me!!! 
    Rebecca

    You should be able to boot to the Snow Leopard upgrade disc — you had to do so to install the upgrade in the first place. If you can't boot to it now, either the disc is scratched or dirty or your drive's lens is dirty; for the latter problem, a drive cleaning disc is an inexpensive, frequently-used and often successful remedy, available at any store that sells DVDs.
    Because you're running Snow Leopard now, you should repair your hard drive directory using the Snow Leopard version of Disk Utility, not the one on your Tiger installer disc. If you aren't able to do so even after trying to clean your drive, you could buy and use DiskWarrior to rebuiild the damaged HD directory. But DW costs nearly $100, and though it would probably do the trick, that's a bunch of money. You'll have to weigh its cost against the value of the new or changed data on your drive that hasn't been backed up in the last three weeks. If you can get along without that data, then erasing your hard drive and restoring from your last backup is the no-cost, immediate (as opposed to waiting for a DW startup disk to arrive in the mail) solution.

  • Receiving Invalid B-tree node size in Disk Utility

    My mac mini has recently bit the dust.  I did a hard shut down by holding down the power button.  Since then I have not been able to bring it back.  It started with a folder with a ? in it.  Sometimes it sits at the apple logo, and other times it goes to a gray screen and just reboots eventually.  I am running Snow Leopard, and I have booted from the install cd.  I have tried running Repair Disk in Disk Utility, but I receive the following error:  "Invalid node structure Invalid B-tree node size The volume could not be verified completely.  Volume repair complete.  Updating boot support partitions for the volume as required.  Error:  Disk Utility can't repair this disk...disk, and restore your backed-up files."
    In the pop up window it says "Disk Utility stopped repairing "macintosh HD" Disk Utility can't repair this disk.  Back up as many of your files as possible, reformat the disk, and restore your backed-up files.  On the left hand side of the window I see 60.01GB ST96812AS Media, and then I see Macintosh HD offset underneath.  The Macintosh HD is in light gray and is not mounted.  When I try to Mount it it gives me an error and tells me to repair the disk. 
    My question is do you think Disk Warrior would work or something like that software?  I tried to do an Archive and Install, but since the HD won't mount I can't do an installation.  Is my HD dead?
    Any help would be appreciated!
    Sincerely,
    Matt

    As you can see, I received no help from this forum.  I ended up replacing the hard drive after trying disk warrior unsuccessfully!  I wish you luck and anyone else who has this issue.
    <a href="http://www.medicare-plans.net">Medicare Man</a>

  • I got the dreaded "Invalid Node Structure" Error

    Hi All,
    I entered the Mac world recently with a spanking new Macbook Pro 15". Updated it online to the latest OS 10.6.4 Snow Leopard.
    Today I was trying to install some more free application from the Official Mac Software Site. After installing a couple of softwares, I popped in the included recovery Disk and tryed installing xcode from the 'additional software' folder on the disk. But this failed
    After this I thought of restarting the mac and try again. However, the **** thing now wouldn't boot anymore. Just stays on the Gray apple screen with the small ring rotating below it for ever.
    Then I tried repairing it using the Disk Utility booting form the DVD. On verify Disk, it shows 'Invalid Node Structure'. So I clicked 'Repair Disk', And it just stayed there for ever without any progress. So I stopped it. And after trying the above 3-4 times, I Hard rebooted the system, and this time entered the console mode (Command + s).
    Entered the command fsck_hfs -rf /dev/disk0s2 (disk0s2 is what Disk Utility showed me).
    The output of this command shows:
    ** /dev/rdisk0s2
    Executing fsck_hfs (version diskdev_cmds-491.0.2~7).
    ** Checking Journaled HFS Plus Volume
    ** Checking extents overflow file
    ** Checking catalog file
    ** Rebuilding catalog B-tree
    disk0s2: I/O error.
    disk0s2: I/O error.
    disk0s2: I/O error.
    disk0s2: I/O error.
    disk0s2: I/O error.
    disk0s2: I/O error.
    disk0s2: I/O error.
    disk0s2: I/O error.
    disk0s2: I/O error.
    disk0s2: I/O error.
    And this goes on and on and on.... :((
    Now what to do???

    Hmmm, yeah that could be the last option, but I can't format the disk right now, 'cause I've some extremely important (not-yet-backed-up) files in it
    So I'd like to try out all possible ways to recover the system before even thinking of a format!
    BTW, the above fsck_hfs command I ran was by booting from the DVD itself.

  • Tree and Tree Node Components - Threadinar7

    Hi All,
    This is the seventh in the "Threadinar" series , please see Threadinar6 at
    http://forum.sun.com/jive/thread.jspa?threadID=100601 for details
    In this Threadinar we will focus on the
    "Tree" and "Tree Node" Components
    Let us begin our discussion with the Tree Component.
    Tree Component
    You can drag the Tree component from the Palette's Basic category to the Visual Designer to create a hierarchical tree structure with nodes that can be expanded and collapsed, like the nodes in the Outline window. When the user clicks a node, the row will be highlighted. A tree is often used as a navigation mechanism.
    A tree contains Tree Node components, which act like hyperlinks. You can use a Tree Node to navigate to another page by setting its url property. You can also use a Tree Node to submit the current page. If the the Tree Node's action property is bound to an action event handler, selecting the node automatically submits the page. If the Tree Node's actionListener property is bound to an action listener, opening or closing the node automatically submits the page. You set Tree Node properties in the Tree Node Component Properties window.
    * If you use this component to navigate between pages of a portlet, do not use the url property to link to a page. Instead, use the Navigation editor to set up your links to pages.
    * Events related to tree node selection do not work correctly in portlets because the component uses cookies to pass the selected node id back and forth, and cookies are not correctly handled by the portlet container. You cannot handle tree node selection events in portlet projects.
    Initially when you drop a tree on a page, it has one root node labeled Tree and one subnode labeled Tree Node 1. You can add more nodes by dragging them to the tree and dropping them either on the root node to create top level nodes or on existing nodes to create subnodes of those nodes. You can also right-click the Tree or any Tree Node and choose Add Tree Node to add a subnode to the node.
    Additionally, you can work with the component in the Outline window, where the component and its child components are available as nodes. You can move a node from level to level easily in the Outline window, so you might want to work there if you are rearranging nodes. You can also add and delete tree nodes in the Outline window, just as in the Visual Designer.
    The Tree component has properties that, among other things, enable you change the root node's displayed text, change the appearance of the text, specify if expanding or collapsing a node requires a trip to the server, and specify whether node selection should automatically open or close the tree. To set the Tree's properties, select the Tree component in your page and use the Tree Component Properties window.
    The following Tutorial ("Using Tree Component") is very useful to learn using Tree components
    http://developers.sun.com/prodtech/javatools/jscreator/learning/tutorials/2/sitemaptree.html
    See Also the Technical Article - "Working with the Tree Component and Tree Node Actions"
    http://developers.sun.com/prodtech/javatools/jscreator/reference/techart/2/tree_component.html
    Tree Node Component
    You can drag the Tree Node component from the Palette's Basic category to a Tree component or another tree node in the Visual Designer to create a node in a hierarchical tree structure, similar to the tree you see in the Outline window.
    The tree node is created as a subnode of the node on which you drop it. If you drop the node on the tree component itself, a new node is created as a child of the root node. You can see the hierarchical structure clearly in the Outline window, where you can also easily move nodes around and reparent them.
    You can also add a tree node either to a Tree component or to a Tree Node component by right-clicking the component and choosing Add Tree Node.
    A Tree Node component by default is a container for an image and can be used to navigate to another page, submit the current page, or simply open or close the node if the node has child nodes.
    * If you select the Tree Node component's node Tree Node icon in the Outline window, you can edit its properties in the Tree Node Properties window. You can set things like whether or not the Tree Node is expanded by default, the tooltip for the Tree Node, the label for the tree node, and the Tree Node's identifier in your web application.
    * You can use a Tree Node to navigate to another page by setting its url property. You can also use a Tree Node to submit the current page. If the the Tree Node's action property is bound to an action event handler, selecting the node automatically submits the page. If the Tree Node's actionListener property is bound to an action listener, opening or closing the node automatically submits the page.
    - Note: If you use this component to navigate between pages of a portlet, do not use the url property to link to a page. Instead, use the Navigation editor to set up your links to pages. In addition, events related to tree node selection do not work correctly in portlets because the component uses cookies to pass the selected node id back and forth, and cookies are not correctly handled by the portlet container. You cannot handle tree node selection events in portlet projects.
    * If you select the image in the Tree Node, you can see that its icon property is set to TREE_DOCUMENT. If you right-click the image on the page and choose Set Image, you can either change the icon to another one or choose your own image in the Image Customizer dialog box. For more information on working with an image in a tree node, see Image component.
    - Note: The image used in a tree node works best if it is 16x16 or smaller. Larger images can work, but might appear overlapped in the Visual Designer. You can right-click the component and choose Preview in Browser feature to check the appearance of the images.
    Please share your comments, experiences, additional information, questions, feedback, etc. on these components.
    ------------------------------------------------------------------------------- --------------------

    One challenge I had experience was to make the tree
    always expanded on all pages (I placed my tree menu
    in a page fragment so I can just import it in my
    pages).Did you solve this problem. It would be interesting to know what you did.
    To expand a node you call setExpanded on the node. Here is some code from a tutorial that a coworker of mine is working on.
    In the prerender method:
           Integer expandedPersonId = getRequestBean1().getPersonId();
             // If expandedPersonId is null, then we are not coming back
            // from the Trip page. In that case we do not want any trip
            // nodes to be pre-selected (highlighted) due to browser cookies.
            if (expandedPersonId==null) {
                try {
                    HttpServletRequest req =(HttpServletRequest)
                    getExternalContext().getRequest();
                    Cookie[] cookies = req.getCookies();
                    //Check if cookies are set
                    if (cookies != null) {
                        for (int loop =0; loop < cookies.length; loop++) {
                            if (cookies[loop].getName().equals
                                    ("form1:displayTree-hi")) {
                                cookies[loop].setMaxAge(0);
                                HttpServletResponse response =(HttpServletResponse)
                                getExternalContext().getResponse();
                                response.addCookie(cookies[loop]);
                } catch (Exception e) {
                    error("Failure trying to clear highlighting of selected node:" +
                            e.getMessage());
            }                  ... (in a loop for tree nodes)...
                      personNode.setExpanded(newPersonId.equals
                                    (expandedPersonId));In the action method for the nodes:
           // Get the client id of the currently selected tree node
            String clientId = displayTree.getCookieSelectedTreeNode();
            // Extract component id from the client id
            String nodeId = clientId.substring(clientId.lastIndexOf(":")+1);
            // Find the tree node component with the given id
            TreeNode selectedNode =
                    (TreeNode) this.getForm1().findComponentById(nodeId);
            try {
                // Node's id property is composed of "trip" plus the trip id
                // Extract the trip id and save it for the next page
                Integer tripId = Integer.valueOf(selectedNode.getId().substring(4));
                getRequestBean1().setTripId(tripId);
            } catch (Exception e) {
                error("Can't convert node id to Integer: " +
                        selectedNode.getId().substring(4));
                return null;
    It would also be great if I can set the tree
    readonly where the user cannot toggle the expand
    property of the tree (hope this can be added to the
    tree functionality).

  • Add/Edit/Delete Tree Nodes using CL_GUI_ALV_TREE

    Hi All,
    I am looking for an example of program with CL_GUI_ALV_TREE that have a functionality of add a tree node, edit a tree node, and delete a tree node.
    I have already looked the BCALV_TREE* demo program but could not able to find a program to add/edit/delete node tree elements.
    Any info on this.
    Thanks
    aRs

    Hello aRs
    Here is a sample report showing how to delete nodes in an ALV tree. The report was copied from BCALV_TREE_01. Search for added code:
    *$ADDED: begin
    *$ADDED: end[/code]
    When you display the tree expand the first folder completely. When entering 'DELETE' into the command field directly the first flight date node will be deleted.
    REPORT ZUS_SDN_BCALV_TREE_01_DELNODE.
    based on: REPORT  bcalv_tree_01.
    Purpose:
    ~~~~~~~~
    This report shows the essential steps to build up a hierarchy
    using an ALV Tree Control (class CL_GUI_ALV_TREE).
    Note that it is not possible to build up this hierarchy
    using a simple ALV Tree Control (class CL_GUI_ALV_TREE_SIMPLE).
    To check program behavior
    ~~~~~~~~~~~~~~~~~~~~~~~~~
    Start this report. The hierarchy tree consists of nodes for each
    month on top level (this level can not be build by a simple ALV Tree
    because there is no field for months in our output table SFLIGHT.
    Thus, you can not define this hierarchy by sorting).
    Nor initial calculations neither a special layout has been applied
    (the lines on the right do not show anything).
    Note also that this example does not build up and change the
    fieldcatalog of the output table. For this reason, all fields
    of the output table are shown in the columns although the fields
    CARRID and FLDATE are already placed in the tree on the left.
    (Of course, this is not a good style. See BCALV_TREE_02 on how to
    hide columns).
    Essential steps (Search for '§')
    ~~~~~~~~~~~~~~~
    1.Usual steps when using control technology.
       1a. Define reference variables.
       1b. Create ALV Tree Control and corresponding container.
    2.Create Hierarchy-header
    3.Create empty Tree Control
    4.Create hierarchy (nodes and leaves)
       4a. Select data
       4b. Sort output table according to your conceived hierarchy
       4c. Add data to tree
    5.Send data to frontend.
    6.Call dispatch to process toolbar functions
    *$ADDED: begin
    DATA:
      gd_del_nkey      TYPE lvc_nkey.
    *$ADDED: end
    §1a. Define reference variables
    DATA: g_alv_tree         TYPE REF TO cl_gui_alv_tree,
          g_custom_container TYPE REF TO cl_gui_custom_container.
    DATA: gt_sflight      TYPE sflight OCCURS 0,      "Output-Table
          ok_code LIKE sy-ucomm,
          save_ok LIKE sy-ucomm,           "OK-Code
          g_max TYPE i VALUE 255.
    END-OF-SELECTION.
      CALL SCREEN 100.
    *&      Module  PBO  OUTPUT
          process before output
    MODULE pbo OUTPUT.
      SET PF-STATUS 'MAIN100'.
      SET TITLEBAR 'MAINTITLE'.
      IF g_alv_tree IS INITIAL.
        PERFORM init_tree.
        CALL METHOD cl_gui_cfw=>flush
          EXCEPTIONS
            cntl_system_error = 1
            cntl_error        = 2.
        IF sy-subrc NE 0.
          CALL FUNCTION 'POPUP_TO_INFORM'
            EXPORTING
              titel = 'Automation Queue failure'(801)
              txt1  = 'Internal error:'(802)
              txt2  = 'A method in the automation queue'(803)
              txt3  = 'caused a failure.'(804).
        ENDIF.
      ENDIF.
    ENDMODULE.                             " PBO  OUTPUT
    *&      Module  PAI  INPUT
          process after input
    MODULE pai INPUT.
      save_ok = ok_code.
      CLEAR ok_code.
      CASE save_ok.
        WHEN 'EXIT' OR 'BACK' OR 'CANC'.
          PERFORM exit_program.
    *$ADDED: begin
        WHEN 'DELETE'.
          CALL METHOD g_alv_tree->delete_subtree
            EXPORTING
              i_node_key                = gd_del_nkey
             I_UPDATE_PARENTS_EXPANDER = SPACE
              i_update_parents_folder   = 'X'
            EXCEPTIONS
              node_key_not_in_model     = 1
              OTHERS                    = 2.
          IF sy-subrc <> 0.
          MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
                     WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
          ENDIF.
          CALL METHOD g_alv_tree->frontend_update.
    *$ADDED: end
        WHEN OTHERS.
    §6. Call dispatch to process toolbar functions
          CALL METHOD cl_gui_cfw=>dispatch.
      ENDCASE.
      CALL METHOD cl_gui_cfw=>flush.
    ENDMODULE.                             " PAI  INPUT
    *&      Form  init_tree
          text
    -->  p1        text
    <--  p2        text
    FORM init_tree.
    §1b. Create ALV Tree Control and corresponding Container.
    create container for alv-tree
      DATA: l_tree_container_name(30) TYPE c.
      l_tree_container_name = 'CCONTAINER1'.
      CREATE OBJECT g_custom_container
         EXPORTING
               container_name = l_tree_container_name
         EXCEPTIONS
               cntl_error                  = 1
               cntl_system_error           = 2
               create_error                = 3
               lifetime_error              = 4
               lifetime_dynpro_dynpro_link = 5.
      IF sy-subrc <> 0.
        MESSAGE x208(00) WITH 'ERROR'(100).
      ENDIF.
    create tree control
      CREATE OBJECT g_alv_tree
        EXPORTING
            parent              = g_custom_container
            node_selection_mode = cl_gui_column_tree=>node_sel_mode_single
            item_selection      = 'X'
            no_html_header      = 'X'
            no_toolbar          = ''
        EXCEPTIONS
            cntl_error                   = 1
            cntl_system_error            = 2
            create_error                 = 3
            lifetime_error               = 4
            illegal_node_selection_mode  = 5
            failed                       = 6
            illegal_column_name          = 7.
      IF sy-subrc <> 0.
        MESSAGE x208(00) WITH 'ERROR'.                          "#EC NOTEXT
      ENDIF.
    §2. Create Hierarchy-header
    The simple ALV Tree uses the text of the fields which were used
    for sorting to define this header. When you use
    the 'normal' ALV Tree the hierarchy is build up freely
    by the programmer this is not possible, so he has to define it
    himself.
      DATA l_hierarchy_header TYPE treev_hhdr.
      PERFORM build_hierarchy_header CHANGING l_hierarchy_header.
    §3. Create empty Tree Control
    IMPORTANT: Table 'gt_sflight' must be empty. Do not change this table
    (even after this method call). You can change data of your table
    by calling methods of CL_GUI_ALV_TREE.
    Furthermore, the output table 'gt_outtab' must be global and can
    only be used for one ALV Tree Control.
      CALL METHOD g_alv_tree->set_table_for_first_display
        EXPORTING
          i_structure_name    = 'SFLIGHT'
          is_hierarchy_header = l_hierarchy_header
        CHANGING
          it_outtab           = gt_sflight. "table must be empty !
    §4. Create hierarchy (nodes and leaves)
      PERFORM create_hierarchy.
    §5. Send data to frontend.
      CALL METHOD g_alv_tree->frontend_update.
    wait for automatic flush at end of pbo
    ENDFORM.                               " init_tree
    *&      Form  build_hierarchy_header
          build hierarchy-header-information
         -->P_L_HIERARCHY_HEADER  strucxture for hierarchy-header
    FORM build_hierarchy_header CHANGING
                                   p_hierarchy_header TYPE treev_hhdr.
      p_hierarchy_header-heading = 'Month/Carrier/Date'(300).
      p_hierarchy_header-tooltip = 'Flights in a month'(400).
      p_hierarchy_header-width = 30.
      p_hierarchy_header-width_pix = ' '.
    ENDFORM.                               " build_hierarchy_header
    *&      Form  exit_program
          free object and leave program
    FORM exit_program.
      CALL METHOD g_custom_container->free.
      LEAVE PROGRAM.
    ENDFORM.                               " exit_program
    *&      Form  create_hierarchy
          text
    -->  p1        text
    <--  p2        text
    FORM create_hierarchy.
      DATA: ls_sflight TYPE sflight,
            lt_sflight TYPE sflight OCCURS 0,
            l_yyyymm(6) TYPE c,            "year and month of sflight-fldate
            l_yyyymm_last(6) TYPE c,
            l_carrid LIKE sflight-carrid,
            l_carrid_last LIKE sflight-carrid.
      DATA: l_month_key TYPE lvc_nkey,
            l_carrid_key TYPE lvc_nkey,
            l_last_key TYPE lvc_nkey.
    §4a. Select data
      SELECT * FROM sflight INTO TABLE lt_sflight UP TO g_max ROWS.
    §4b. Sort output table according to your conceived hierarchy
    We sort in this order:
       year and month (top level nodes, yyyymm of DATS)
         carrier id (next level)
            day of month (leaves, dd of DATS)
      SORT lt_sflight BY fldate0(6) carrid fldate6(2).
    Note: The top level nodes do not correspond to a field of the
    output table. Instead we use data of the table to invent another
    hierarchy level above the levels that can be build by sorting.
    §4c. Add data to tree
      LOOP AT lt_sflight INTO ls_sflight.
    Prerequesite: The table is sorted.
    You add a node everytime the values of a sorted field changes.
    Finally, the complete line is added as a leaf below the last
    node.
        l_yyyymm = ls_sflight-fldate+0(6).
        l_carrid = ls_sflight-carrid.
    Top level nodes:
        IF l_yyyymm <> l_yyyymm_last.      "on change of l_yyyymm
          l_yyyymm_last = l_yyyymm.
    *Providing no key means that the node is added on top level:
          PERFORM add_month USING    l_yyyymm
                                 CHANGING l_month_key.
    The month changed, thus, there is no predecessor carrier
          CLEAR l_carrid_last.
        ENDIF.
    Carrier nodes:
    (always inserted as child of the last month
    which is identified by 'l_month_key')
        IF l_carrid <> l_carrid_last.      "on change of l_carrid
          l_carrid_last = l_carrid.
          PERFORM add_carrid_line USING    ls_sflight
                                           l_month_key
                                  CHANGING l_carrid_key.
        ENDIF.
    Leaf:
    (always inserted as child of the last carrier
    which is identified by 'l_carrid_key')
        PERFORM add_complete_line USING  ls_sflight
                                         l_carrid_key
                                CHANGING l_last_key.
      ENDLOOP.
    ENDFORM.                               " create_hierarchy
    *&      Form  add_month
    FORM add_month  USING     p_yyyymm TYPE c
                              p_relat_key TYPE lvc_nkey
                    CHANGING  p_node_key TYPE lvc_nkey.
      DATA: l_node_text TYPE lvc_value,
            ls_sflight TYPE sflight,
            l_month(15) TYPE c.            "output string for month
    get month name for node text
      PERFORM get_month USING p_yyyymm
                        CHANGING l_month.
      l_node_text = l_month.
    add node:
    ALV Tree firstly inserts this node as a leaf if you do not provide
    IS_NODE_LAYOUT with field ISFOLDER set. In form 'add_carrid_line'
    the leaf gets a child and thus ALV converts it to a folder
    automatically.
      CALL METHOD g_alv_tree->add_node
        EXPORTING
          i_relat_node_key = p_relat_key
          i_relationship   = cl_gui_column_tree=>relat_last_child
          i_node_text      = l_node_text
          is_outtab_line   = ls_sflight
        IMPORTING
          e_new_node_key   = p_node_key.
    ENDFORM.                               " add_month
    FORM add_carrid_line USING     ps_sflight TYPE sflight
                                   p_relat_key TYPE lvc_nkey
                         CHANGING  p_node_key TYPE lvc_nkey.
      DATA: l_node_text TYPE lvc_value,
            ls_sflight TYPE sflight.
    add node
    ALV Tree firstly inserts this node as a leaf if you do not provide
    IS_NODE_LAYOUT with field ISFOLDER set. In form 'add_carrid_line'
    the leaf gets a child and thus ALV converts it to a folder
    automatically.
      l_node_text =  ps_sflight-carrid.
      CALL METHOD g_alv_tree->add_node
        EXPORTING
          i_relat_node_key = p_relat_key
          i_relationship   = cl_gui_column_tree=>relat_last_child
          i_node_text      = l_node_text
          is_outtab_line   = ls_sflight
        IMPORTING
          e_new_node_key   = p_node_key.
    ENDFORM.                               " add_carrid_line
    *&      Form  add_complete_line
    FORM add_complete_line USING   ps_sflight TYPE sflight
                                   p_relat_key TYPE lvc_nkey
                         CHANGING  p_node_key TYPE lvc_nkey.
      DATA: l_node_text TYPE lvc_value.
      WRITE ps_sflight-fldate TO l_node_text MM/DD/YYYY.
    add leaf:
    ALV Tree firstly inserts this node as a leaf if you do not provide
    IS_NODE_LAYOUT with field ISFOLDER set.
    Since these nodes will never get children they stay leaves
    (as intended).
      CALL METHOD g_alv_tree->add_node
        EXPORTING
          i_relat_node_key = p_relat_key
          i_relationship   = cl_gui_column_tree=>relat_last_child
          is_outtab_line   = ps_sflight
          i_node_text      = l_node_text
        IMPORTING
          e_new_node_key   = p_node_key.
    *$ADDED: begin
      IF ( ps_sflight-fldate = '20040522' ).  " first flight date
        IF ( gd_del_nkey IS INITIAL ).  " collect only first date
          gd_del_nkey = p_node_key.
        ENDIF.
      ENDIF.
    *$ADDED: end
    ENDFORM.                               " add_complete_line
    *&      Form  GET_MONTH
          text
         -->P_P_YYYYMM  text
         <--P_L_MONTH  text
    FORM get_month USING    p_yyyymm
                   CHANGING p_month.
    Returns the name of month according to the digits in p_yyyymm
      DATA: l_monthdigits(2) TYPE c.
      l_monthdigits = p_yyyymm+4(2).
      CASE l_monthdigits.
        WHEN '01'.
          p_month = 'January'(701).
        WHEN '02'.
          p_month = 'February'(702).
        WHEN '03'.
          p_month = 'March'(703).
        WHEN '04'.
          p_month = 'April'(704).
        WHEN '05'.
          p_month = 'May'(705).
        WHEN '06'.
          p_month = 'June'(706).
        WHEN '07'.
          p_month = 'July'(707).
        WHEN '08'.
          p_month = 'August'(708).
        WHEN '09'.
          p_month = 'September'(709).
        WHEN '10'.
          p_month = 'October'(710).
        WHEN '11'.
          p_month = 'November'(711).
        WHEN '12'.
          p_month = 'December'(712).
      ENDCASE.
      CONCATENATE p_yyyymm+0(4) '->' p_month INTO p_month.
    ENDFORM.                               " GET_MONTH
    /code
    Regards
      Uwe

  • Invalid B-tree node size (3,0) error - what is it??

    Yesterday I had a HDD issue on my iMac (OSX 10.5) with an 'invalid node structure' error. I eventually managed to boot into 'single user mode' and used #fsck_hfs -rf /dev/disk0s2 at the command prompt. This got OSX up and running properly again. I then repaired the permissions and the disk using the disk repair utility.
    Today, I have had a complete system freeze which necessitated a cold reboot. Since then nothing has worked. I can't boot in safe mode, single user mode or verbose mode. I tried resetting the PRAM and attempted to boot from a system install disk without initial success. After about half an hour the disk icon appeared on the screen and I could boot from the install disk. I then used the terminal to try 'fsck_hfs -rf' again. This time I got the error 'Invalid B-tree node size (3,0)'. What does this mean and what do I do now?? Most forums seem to suggest using 'Disk Warrior'. Since this costs about $170 in Australia I am unlikely to take this option. Having been unemployed for more than 5 months I am more likely to attempt replacing the drive myself. However, I'd prefer to take another approach if there is one. Any suggestions?? Would it be better to give up on replacing the internal drive and try for a bootable external HDD? Too slow?

    HI and Welcome to Apple Discussions...
    Check out TechToolPro but they might be even more $$$.
    Unfortunately, it takes a robust disk utility to repair an invalid tree node. Your best bet really is DiskWarrior
    *"Would it be better to give up on replacing the internal drive and try for a bootable external HDD? Too slow? "*
    You could use a bootable external drive but there again you are looking at an investment.
    Carolyn
    Message was edited by: Carolyn Samit

  • Invalid B-tree node size error & updating OS

    I was toying around with the idea of updating my OS to 10.4 and increasing my storage capacity. A welcome upgrade to an old system that has been very good to me....until now.
    The short version is that I am experiencing quite a bit of directory damage (for the full story, read below). After researching hundreds of posts here, I think my best bet is to purchase Disk Warrior. My question is, which version should a purchase? As a result of the work I've explained below, my system is currently running the version installed from my OSX Install CD. I'm not sure what version this is, but my Mac came with CDs for OS9, OSX, and an upgrade to 10.2.8. Is there a version of Disk Warrior that will support 10.2-10.4? I want to fix the current issues but still be able to use this software when (or IF) I upgrade.
    I'm happy to provide any info needed and appreciate ANY help. Thanks,
    On a routine startup I encountered the stalled progress indicator (spinning gear) and its been downhill from there. I've scoured the Mac forums here for possible fixes, but so far nothing has been able to completely solve my problem. Here's a brief rundown of what I have done so far:
    1) Booted from OSX Install CD and ran disk utility. This verified I had catalog and node errors that could not be repaired.
    2) Ran Apple Hardware test from CD. Everything was fine.
    3) Ran TECHTool Pro that came with my AppleCare CD and identified similar errors but could not repair them. At this point I also got an "Invalid Sibling Link" error.
    Finally I decided that the data I had saved on my HD was not crucial so I would attempt a reinstall of the OS and lose what was not backed up. So I:
    5) Performed reinstall from OSX Install CD.
    6) Ran Disk Utility, all was fine.
    At this point I was able to run programs and boot up normally. Of course this was too good to be true, and it was, because subsequent restarts gave me even more errors! I was again experiencing the freeze at startup, although this time I was getting the Mac computer logo with smiley face icon for all eternity.
    7) Again booted from OSX Install CD and ran Disk Utility. I'm now getting an "Invalid B-tree node size" error. I;ve tried all the cycles with repair utilities to no avail. I am also unable to start up in single user mode so I'm stuck.
    iMac G4 Flat Panel   Mac OS X (10.2.x)   Purchased 2002
    iMac G4 Flat Panel   Mac OS X (10.2.x)   Purchased 2002

    Thanks! I will order DW and give it a try...
    I have run the Apple Hardware diagnostic CD twice (at different points in this process) and everything has come back cleanly. I am fairly certain this is a directory issue, but we'll wait and see. At the very least I will have DW to back up any future systems.
    This is sortof off topic, but what is the general service fee for visiting the Genius Bar? I consulted a Mac pro there to discuss an upgrade to my system, but there was no charge. I find this hard to believe...does anyone know? I can't seem to find anything online...

  • Invalid B-tree node size

    So I used techtool 4 to try to improve my performance. There weren't any problems before, but I figured "Hey, I might as well." Suddenly both drives disappeared and techtool 4 told me they aren't there. I tried Disk Utility, but it gave me the error message "Invalid B-tree node size." I have no idea what that means and I have some extremely valuable information on that drive that I haven't backed up yet. I don't have $100 to throw away on Disk Warrior either. Is there any other solution that I can do to fix this problem that techtool 4 seemed to have caused.

    You analyzed it with Disk Utility but it won't mount? Did you try to mount it with Disk Utility?
    Try using an application such as [Data Rescue II|http://www.prosofteng.com/products/data_rescue.php] or [FileSalvage|http://subrosasoft.com/OSXSoftware/index.php?mainpage=product_info&productsid=1]. Both have free trial versions that let you see if the software will help before you decide to buy. You will also need a second hard drive equal to or larger in size than your first drive.
    There is also this free tool which supposedly runs on OSX and does recovery of popular media and Office files. http://www.cgsecurity.org/wiki/TestDisk_Download
    I have not seen any reports from anybody who has actually used this tool and the documentation is not terribly clear so it really is an unknown as far as I am concerned.

  • Volume won't boot: Invalid B-tree node size

    My OS 10.4 volume on a G4 tower will no longer boot (I can mount it from another volume on the same machine, though).
    The problem started with trying to read from a damaged CD. I powered-off the machine when it hung trying to copy a file. After I could no longer boot. Disk utility said bad leaf record count (I think). The utility could not do the repair, fsck didn't help.
    I have a copy of Techtool deluxe (that came with a Tiger-loaded G5). I ran that. It found, and claimed to have repaired, the problems (though it took a looong time). Techtool now finds no errors.
    However, I still cannot boot. Running diskutility get me:
    Invalid B-tree node size
    Error: the underlying task reported failure on exit (-9972)
    Trying to boot in single-user mode gets a nasty panic.
    I guess my question is: Is it worth trying to run another repair utility? If Techtool thinks everything is OK, is there any point doing more? Did I mess this up by using the Techtool that came with a G5 on my G4? (not sure I want the answer to that last question.)
    Thanks for any pointers.
    g4 tower   Mac OS X (10.4.3)  

    Thanks for the tips. I could have swornTechtool deluxe came with machines loaded with Tiger, but I guess not.
    Before I messed things too badly with Techtool delux I made an image of the volume. It still has the bad leaf count, but at least it could mount.
    I'm going to erase the volume, reinstall the system software and then copy all my files off the diskimage. One more question: If I want to copy applications from the diskimage should I copy anything besides the stuff in the Applications folder? something from the Library?
    Thanks again.

  • Is my hard drive dead? Invalid B-Tree Node Size

    When I turn on my powerbook it goes to the grey screen with the apple in the middle comes up and then it goes to loading Mac OS X which I am trying to do but when it comes to Select a Destination my hard drive is not listed. I click on utilities and go to utilities and disk utility. My hard drive is listed on the left side so i click it. I then click verify disk and it sais Invalid B-Tree Node Size and Volume needs repair. Then I click repair but the same thing comes up. What can I do? PS-I did a search but none of the info I came up with helped me at all.

    they are about $100 and available from most Apple dealers:
    http://alsoft.com/DiskWarrior/index.html
    http://www.micromat.com/
    if there are no important files on the drive, erasing the drive and reinstalling OS could possibly fix it unless it's caused by failing drive hardware.
    if erase/install does not work properly, could be bad drive.
    "B-Tree" message could simply be caused by messed up files and there is nothing wrong with the drive itself.

  • Invalid B tree node size- Computer won't start up anymore

    Get the kernel panic/restart messsage - when I restart same thing.... Tried all of the solutions Apple suggest- re-setting PRAM, holding the "X" key, holding the "option" key... nothing seems to work. Ran the OSX install CD and went to utilites, tried to repair the disk that way- but get the message- " Invalid B Tree node size, volume check failed. Error: The underlying task reported failure on exit. IHFS Volume checked - Volume could not be repaired beause of an error.
    CD would also not let me re- install OS X
    Currently using OS X 10.4.9 on a G4 iMac

    Owen:
    Thank you for posting back with an update of your situation. I am glad you were able to work your way through your issues and secure your Users Folder. Data Resuce II is a great tool.
    I have been using different versions of TechTool Pro since OS 9 and have found it to be a great tool. It has saved me from disaster several times. I use TechTool Pro 4.5.2 on Tiger. I am not sure what version you were using, but if, indeed, TTP damaged your data, and I have serious doubts about that, it could be that you were using the wrong version.
    Having a good backup strategy is very important. You will find some good hints in Dr. Smoke's FAQ Backup and Recovery. My main difference with Dr. Smoke is the he insists on using Retrospect as his backup software, whereas I have never been able to get it to work. Besides, you will find that SuperDuper is much friendlier and efficient. Indeed, SuperDuper was rated the best backup software in tests. And no need to wait for Leopard to do scheduled backups. SuperDuper will do that, too.
    Again, I am glad your issue has been resolved. Use Disk Warrior regularly to rebuild your directories and follow a regular maintenance schedule such as the one Gulliver suggests in his article Mac OS X System Maintenance.
    Happy Mac Computing.
    cornelius
    Message was edited by: cornelius

  • Kernel panic/invalid node structure; please help retrieving my files!!

    Hi everyone, thank you for your time in advance... if anyone has ideas about how to solve it, I appreciate this very much!
    OK, here is how it began: while I was working on the airplane using PowerPoint, the gray spinning wheel appeared after which PowerPoint stopped working. I pressed the power button to exit (all applications froze). (So much for trying to get more work done...)
    Next, I powered up the computer but it would not boot up, with only gray spinning wheel showing.
    Next, tried to boot up while pressing power button and holding shift key. After some time (10 minutes), an error message appears. Researching it on discussion forums, I found that it is called “kernel panic”. Here is beginning of the message:
    panic(cpu 1 caller 0x47f5ad): "Process 1 exec of /sbin/launchd failed, errno 8\n"@SourceCache/xnu/xnu-1504.15.3/bsd/kern/kern_exec.c:3145
    Debugger called: <panic>
    [additional information here]
    Also, message “You need to restart your computer. Hold down the Power button until it turns off, then press the Power button again” is shown transparently in the middle of the screen over the “panic” message output.
    I turned on and off the Power button many times, but I get the same error message.
    I also tried Apple Hardware Test but it did not work (it did not generate any messages).
    Next, I tried to use the Disk Utility using the Installation Disk that came with the computer. After I clicked “Disk Repair”, here is the log:
    Verify and Repair volume “Macintosh HD”
    Checking Journaled HFS Plus volume.
    Checking extents overflow file.
    Checking catalog file.
    Invalid node structure
    Rebuilding catalog B-tree.
    Invalid node structure
    [many repeats of “Invalid node structure”  ~ about 400 repeats]
    Rechecking volume.
    Checking Journaled JFS Plus volume.
    Checking extents overflow file.
    Checking catalog file.
    Missing thread record (id=18)
    Missing thread record (id=110)
    [many instances of “Missing thread record” ~about 200 repeats]
    Checking multi-linked files.
    Checking catalog hierarchy.
    Checking extended attributes file.
    The volume Macintosh HD could not be verified completely.
    Error: Disk Utility can’t repair this disk…disk, and restore your back-up files.
    At the end, a window presented over the error log stated :
    “Disk Utility stopped repairing “Macintosh HD”
    Disk Utility can’t repair this disk. Back up as many of your files as possible, reformat the disk, and restore your back-up files.
    I need to retrieve my recent files!! Please Help!! Argh!! I promise that I will promptly back up my files now! I did not use Time Machine, and only some of my files are backed up.
    From what I read on the discussion forum, I will probably need to erase the disk and then do a fresh installation, but could someone please guide me with regard to how to back up the data / retrieve the files? I may have access to another mac so I’m thinking that the FireWire Target Disk Mode may work. I also have spare external harddrive (formatted for mac) (not partitioned). Also, how do I retrieve the files from the other computer if the FireWire transfer works?
    Also, the second step is to do a new installation, but is there any reason why “Archive and Install” using Disk Utility won’t help? I have some additional programs installed (Illustrator, Photoshop) so this means if I do a new installation, I will need to re-install those as well?
    I did some investigation, and it looks like this problem is similar to this:
    https://discussions.apple.com/message/18098343#18098343
    But my main issue now is to retrieve the files!
    Also, how do I investigate whether this problem is due to a failing hard drive or a natural file system corruption ? (so should I get a new harddrive or do a new install).
    http://forums.macnn.com/t/459376/heart-attack-invalid-node-structure
    I don’t know what is the OS version;  it is Snow Leopard OS X ……. I bought it in September 2009.
    I appreciate any help, thank you so much for your time…

    Create a data recovery/undelete external boot drive
    Step by Step to fix your Mac
    Most commonly used backup methods

Maybe you are looking for

  • Screen goes black when making phone calls

    Hi, I have started to use a new Xperia Z2 a short while ago. As soon as I am tapping the screen to call a phone number the screen goes black; I can hear the phone calling but can't see anything (not being able to turn on loudspeaker etc.). The sound

  • Factory method usage, creating the correct Image subclass

    Hi, I created a factory method   public enum ImgType {     SINGLE, STRIP, SPRITE_SHEET public static Image createImage(ImgType imgType) {     switch (imgType) {       case SINGLE:         return new MyImage1(0, 0);       case SPRITE_SHEET:         re

  • Web Dynpro question, need direction!

    I need to design an application or webpage that will run from a link in an e-mail, and that will pull, display, and send some SAP R3 portal content. I've been playing with Netweaver Developers Studio / Web Dynpro, and have made a basic application/pa

  • HDCP message on playback

    I'm gettting that "HDCP" message when I try to play a movie I rented.  Have tried all the normal fixes, but none work.  Any suggestions?

  • Annoying Yellow Boxes - Mac OS 10.4.10

    I am becoming annoyed at the appearances of "Yellow Boxes" that appear everywhere in Mac OS 10.4.10. To help provide an explanation, I have put an image of an example of one of them on Flickr. You can see the page with the image and a description of